MicroStrategy的SDK開發介紹6課件_第1頁
MicroStrategy的SDK開發介紹6課件_第2頁
MicroStrategy的SDK開發介紹6課件_第3頁
MicroStrategy的SDK開發介紹6課件_第4頁
MicroStrategy的SDK開發介紹6課件_第5頁
已閱讀5頁,還剩17頁未讀 繼續免費閱讀

下載本文檔

版權說明:本文檔由用戶提供并上傳,收益歸屬內容提供方,若內容存在侵權,請進行舉報或認領

文檔簡介

1、Web對象API介紹1Java SDK包結構介紹Java XML API 總覽 集群 重要的設置Utilities API介紹WebObjects API API總覽 WebObjectSource和Object瀏覽 WebReportSource和Report操作 WebPrompts和WebDisplayHelper 鉆取界面 表格對象模型日程2Java SDK包結構Com.microstrategyWebobjectsbeanstransformpreferenceswebapiutilsSDK標準包除utils和XMLAPI所有SDK APIWeb objects APIWeb bea

2、nsWeb transformPreferences APIJava XMLAPIUtils包3什么是Java XMLAPI?用于處理與Intelligence Server底層通信的API有16個對象,超過100個方法,無狀態,過程所有出入參數都是簡單值或XML結構是基于COM的XMLAPI的直接接口為COM調用者提供了一個基于COM的JNI橋通過TCP/IP sockets與Intelligence Server通信管理與所有可連接服務器的連接池支持服務器群集和負載均衡在3層Intelligence Server API中功能的子集大多數與Intelligence Server的通信是基于

3、XML的可以工作在使用了Java虛擬機的任何平臺上Java XMLAPI總覽4當前,建議使用更高層次的API,例如Web Objects API,來代替直接調用XMLAPI為什么要用更高層次的API?開發代碼快XML難于理解和解釋高層次的API比下層的API更符合面向對象屏避了XMLAPI修改所造成的影響Java XMLAPI總覽5以下所有設置都在IDSSXMLAdmin可用,除了連接池大小和負載因子,它們在IDSSXMLClusterNode上可用設置:連接池大小當連接到服務器時,連接池的初始化大小和最大數目均可設置初始化大小當前創建的連接數最大值可以創建的最大連接數服務器忙timeout當

4、池中所有連接都在忙時,線程將在拋出錯誤之前等待一個連接被空閑這么長的時間請求Timeout到Intelligence Server所有連接的socket timeout。如果服務器在該時間內沒有響應,將拋出錯誤保持活動設置是否在指定間隔內向I-Server發出一個保持活動的信號,以使連接保持活動狀態。該時間間隔在操作系統一級設置負載平衡因子群集中各服務器間的不平衡因素因子加密缺省時只有密碼被加密發送至I-Server,可以設置所有XML字符串均加密發送Java XMLAPI重要的設置7一系列的utilities AP包含在SDK包com.microstrategy.utils中按功能劃分該包:

5、com.microstrategy.utiles包括了一些獨立的應用類(例如URL編碼/解碼,DateTimeConverter) com.microstrategy.utiles.cache緩存處理,用來創建多線程共享緩存 com.microstrategy.utiles.concurrent用來管理多線程對變量的訪問 com.microstrategy.utiles.crypto包含了加密實現類。API使用者可以用IDSSXMLEncryptor XMLAPI對象來訪問該包中的功能 com.microstrategy.utiles.localization本地化類,包含了SDK組件使用的本

6、地化字符串。 com.microstrategy.utiles.log日志處理 com.microstrategy.utiles.pdf包含了訪問本機類的接口來生成PDF com.microstrategy.utiles.serialization包含了連接接口的定義,以及多個與關聯到連接SDK對象的應用 com.microstrategy.utiles.xmlXML應用包。該API用來抽取出對所用的XML解析器的任何依賴性,包含了DOM和SAX的解析方法Utilities API總覽8類圖描述WebObjects Factory會話管理第一個類對象WebObjectInfoFolder對象對

7、象瀏覽Folder瀏覽樣例代碼Search樣例代碼文檔介紹開發者庫Java文檔練習WebObjects API總覽10類圖描述繼承關系(例如B從A繼承)連接線(接口間的關系)聚合:接口間沒有必然的關聯,即某個接口的數據成員可以單獨存在組合:接口間有必然的關聯,即第二個類對象與第一個類對象共存亡對應關系:多值,可選,必選10.*11WebObjects API總覽Web API中共有超過400個接口,WebObjects有約188個接口,大約2000個方法和屬性+getInstance():WebObjectsFactory+getObejctSource():WebObjectSource+g

8、etScheduleSource():WebScheduleSource+getReportSource():WebReportSource+getElementSourceObject():WebElementSource+getIServerSession():WebIServerSession+getDocumentSource():WebDocumentSource+getInboxSource():WebInboxSource+getSubscriptionsSource():WebSubscriptionsSource+getProjectSource():WebProjectSo

9、urce+getClusterAdmin():WebClusterAdmin+checkUserPrivilege(privilegeType:int):boolean接口Com.microstrategy.web.objects.WebObjectsFactoryWebScheduleSourceWebSubscriptionSourceWebObjectSourceWebReportSourceWebInboxSource12WebObjects API會話管理+getSessionID():String+getSessionID(create:boolean):String+getSes

10、sionID(sessionID:String):void+getLogin():String+setLogin(login:String):void+setPassword(password:String):void+closeSession():void+getUserInfo():WebObjectInfo+isAlive():boolean+refresh():void+reconnect():void+getFactory():WebObjectsFactory接口Com.microstrategy.web.objects.WebSessionInfo設置Credentials+ge

11、tServerName():String+getServerName(serverName:String):void+getServerPort():init+setServerPort(portNumber:int):void+getProjectName():String+setProjectName(projectName:String):void接口Com.microstrategy.web.objects.WebIServerSession設置Server,Port和Proejct+saveState(howMuchState:int):String+saveState():Stri

12、ng+restoreState(state:String):boolean接口Com.microstrategy.utils.serialization.Persistable在factory和session間有一對一關系14WebObjects API會話管理+getID():String+getType():int+getSubType():int+getName():String+getAbbreviation():String+getDescription():String+getCreationTime():String+getModificationTime():String+is

13、Hidden():boolean+getAccessGranted():int+getState():int+getOwner():WebObjectInfo+getPropertySets():WebPropertyGroup+getAncestors():SimpleList+getParent():WebFolder接口Com.microstrategy.web.objects.WebObjectInfo+getID():int+getName():String+getType():int+getUseDefault():boolean+getUseDefault(useDefault:

14、 boolean):void+getDefaultValue():String+getValue():String+setValue(value:String):void+isDirty():boolean+save():void接口.objects.WebProperty接口Com.microstrategy.web.objects.WebDisplayUnit+getFilterType():int+getExpression():WebExpression接口 PersistableCom.microstrategy.web.objects.WebFilter接口 Persistable

15、.objects.WebSearch接口.objects.WebTemplate接口.objects.WebProjectGroup接口.objects.WebDimension接口.objects.WebAttribute接口.objects.WebPropertySet有大約28個接口從WebObjectInfo繼承而來11110.*0.*15WebObjects APIWebFolder+getObject(objectID:String,objectType:int,populate:boolean):WebObjectInfo+getObject(objectID:String,ob

16、jectType:int):WebObjectInfo+getObject(objectID:String,objectType:int,objectSubType:int):WebObjectInfo+getObject(objectID:String,objectType:int ,objectSubType:int,populate:boolean):WebObjectInfo+getRoot():WebFolder+getBlockBegin():int+getBlockBegin(blockBegin:int):void+getBlockCount():int+getBlockCou

17、nt(blockCount:int):void+getFlags():int+setFlags(flags:int):void接口Com.microstrategy.web.objects.WebObjectSource接口 WebDisplayUnitCom.microstrategy.web.objects.WebObjectInfo.web.objects.WebFolder.web.objects.WebAttribute10.*Default=true17WebObjects APIFolder瀏覽+getObject(objectID:String,objectType:int,p

18、opulate:boolean):WebObjectInfo+getRoot():WebFolder接口Com.microstrategy.web.objects.WebObjectSource.web.objects.WebIServerSession+getInstance():WebObjectsFactory+getObjectSource():WebObjectSource+getIServerSession():WebIServerSession接口Com.microstrategy.web.objects.WebObjectsFactory11WebSessionInfo11We

19、bDisplayUnit.web.objects.WebObjectInfo.web.objects.WebFolder10.*18Folder瀏覽樣例代碼Try /Create WebObjects factory. WebObjectsFactory factory = WebObjectsFactory.getInstance(); /Setup the session information. WebIServerSession session = factory.getIServerSession(); session.setServerName(“FIRSTBI”); sessio

20、n.setServerPort(0); session.setProjectName(“MicroStrategy Tutorial”); session.setLogin(“Administrator”); session.setPassowrd(“”); /Trigger session creation. String sessionID = session.getSessionID(); /Obtain the objectSource. WebObjectSource objSource = factory.getObjectSource(); /Get the root folde

21、r. WebFolder rootFolder = objSource.getRoot(); /Display the contents of the root folder. for(int=0 ; I rootFolder.size(); I+) WebObjectInfo object = rootFolder.get(I); System.out.println(“Object Name:”+object.getName()+”t”+”Object Type:”+object.getType(); catch(WebObjectExeception exp) System.out.pr

22、intln(“Unexpected error.Error code:”+exp.getErrorCode()+ ”Error Message:”+exp.getMessage();輸出:Object Name:Project Builder Object Type: 8Object Name:Project Objects Object Type: 8Object Name:Public Objects Object Type: 8Object Name:Schema Objects Object Type: 819WebObjects APISearch+getNewSearchObjec

23、t():WebSearch接口Com.microstrategy.web.objects.WebObjectSourceWebDisplayUnit.web.objects.WebObjectInfo.web.objects.WebFolder10.*+getDomain():int+setDomain(domain:int):void+getMaxObjects():int+setMaxObjects(maxObjects:int):void+getNamePattern():String+setNamePattern(namePattern:String):void+getSearchOw

24、ner():String+setSearchOwner(searchOwner:String):void+getSearchRoot():String+setSearchRoot(searchRoot:String):void+types():SimpleList+usedBy():SimpleList+uses():SimpleList+submit():void+submit(searchXML:String):void+getStatus():int+getSearchID():String+setSearchID(searchID:String):void+isAsync():bool

25、ean+setAsync(async:boolean):void+getMaxWait():int+setMaxWait(millis:int):void+getPollingFrequency():int+setPollingFrequency(millis:int):void+getResults():WebFolder+purge():void+reset():void接口 PersistableCom.microstrategy.web.objects.WebSearch1120Folder瀏覽樣例代碼/Get the new search object.WebSearch search = objSource.getNewSearchObject();/Specify the search criteria.Search.types().add(new Integer(EnumDSSXMLObjectTypes.DssXmlTypeDimension);Search.types().add(new Integer(EnumDSSXMLObjectTypes.DssXmlTypeAttribute);/Setup some other properties

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯系上傳者。文件的所有權益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網頁內容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經權益所有人同意不得將文件中的內容挪作商業或盈利用途。
  • 5. 人人文庫網僅提供信息存儲空間,僅對用戶上傳內容的表現方式做保護處理,對用戶上傳分享的文檔內容本身不做任何修改或編輯,并不能對任何下載內容負責。
  • 6. 下載文件中如有侵權或不適當內容,請與我們聯系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論