2012-07-16 18:09 Mule的cloudhub学习(2):开始??????????????? 2.?Mule的message包括以下部分Payload?–?th
2012-07-16 18:09 Mule的cloudhub学习(2):开始
???????????????
2.?Mule的message包括以下部分
Payload?–?this?is?the?actual?data?that?we?are?concerned?with?in?this?application
Properties—Along?with?a?set?of?standard?parameters,?user?defined?parameters?may?be?included?as?well.?? We?access?an?“inbound?property”?in?this?application?to?view?the?URL?query?parameter.
Attachments—Although?not?used?in?this?projects,?other?applications?may?include?attachments?such?as?a XML?file?or?PDF?attachment.
3.?Mule?Expression?Language是Mule专门用来处理Mule的消息的语言,这里的工程用的#[message.inboundProperties['http.query.params']['tweet']]表示获取消息的inbound属性中的http参数中的tweet参数的值。
payload由以下部分组成,可以使用payload.name获得值,比如#[payload.text]获得payload的text。
?
createdAt=Tue?Jul?17?06:34:10?UTC?2012,
?id=225116163082956800,?text='I?built?a?new?CloudHub?application',?source='yaoxianglongExample',?isTruncated=false,?inReplyToStatusId=-1,?inReplyToUserId=-1,?isFavorited=false,?inReplyToScreenName='null',?geoLocation=null,?place=null,?retweetCount=0,?wasRetweetedByMe=false,?contributors=null,?annotations=null,?retweetedStatus=null,?userMentionEntities=[],?urlEntities=[],?hashtagEntities=[],?user=UserJSONImpl{id=700452060,????????????????????????????????????name='yaoxianglong',????????????????????????????????????screenName='yaoxianglong',?????????????????????????????????location='null',????????????????????????????????????????description='',???????????????????????????????????isContributorsEnabled=false,?????????????????????????????????????profileImageUrl='http://a0.twimg.com/profile_images/2405030851/__1_normal.jpg',???????????????????????????????????profileImageUrlHttps='https://si0.twimg.com/profile_images/2405030851/__1_normal.jpg',????????????????????????????????????url='null',????????????????????????????????????isProtected=false,????????????????????????????????????followersCount=0,????????????????????????????????????????????????status=null,?????????????????????????????????????????profileBackgroundColor='C0DEED',???????????????????????????????????????profileTextColor='333333',???????????????????????????????????????profileLinkColor='0084B4',??????????????????????????????????????????profileSidebarFillColor='DDEEF6',??????????????????????????????????????profileSidebarBorderColor='C0DEED',??????????????????????????????????????profileUseBackgroundImage=true,??????????????????????????????????????showAllInlineMedia=false,??????????????????????????????????????friendsCount=11,?????????????????????????????????????createdAt=Tue?Jul?17?05:45:06?UTC?2012,???????????????????????????????????????favouritesCount=0,???????????????????????????????????????utcOffset=-1,???????????????????????????????????????timeZone='null',??????????????????????????????????????????profileBackgroundImageUrl='http://a0.twimg.com/images/themes/theme1/bg.png',?????????????????????????????????????????profileBackgroundImageUrlHttps='https://si0.twimg.com/images/themes/theme1/bg.png',??????????????????????????????????????profileBackgroundTiled=false,???????????????????????????????????????lang='zh-cn',????????????????????????????????????????statusesCount=1,???????????????????????????????????????isGeoEnabled=false,????????????????????????????????????????isVerified=false,???????????????????????????????????????????translator=false,????????????????????????????????????????????listedCount=0,???????????????????????????????????????????isFollowRequestSent=false}}