Java Doc for PackageAdministration.java in  » Workflow-Engines » shark » org » enhydra » shark » api » client » wfservice » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Workflow Engines » shark » org.enhydra.shark.api.client.wfservice 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.enhydra.shark.api.client.wfservice.PackageAdministration

All known Subclasses:   org.enhydra.shark.ws.PackageAdministrationWrapper,  org.enhydra.shark.PackageAdmin,
PackageAdministration
public interface PackageAdministration (Code)
Interface used to perform some administrative operations related to packages (XPDLs).
author:
   Sasa Bojanic
author:
   Vladimir Puskas




Method Summary
 voidclearXPDLCache(WMSessionHandle shandle)
     Clears XPDL caches.
 WMEntityIteratorcloseAllPackagesForId(WMSessionHandle shandle, String id)
     Allows administrator to unload all package versions with the given id from shark. After successful unload, there will no longer be possible to instantiate processes from definitions that were contained within that package.
Parameters:
  id - The id of package that is loaded into engine, and has to be closed.
throws:
  Exception - If something unexpected happens.
 WMEntityclosePackage(WMSessionHandle shandle, String id, String ver)
     Allows administrator to unload the package with the given id and given version from shark.
 StringgetCurrentPackageVersion(WMSessionHandle shandle, String pkgId)
     Returns the current version of the package.
Parameters:
  pkgId - Id of package which current version we want to know.
 String[]getOpenedPackageIds(WMSessionHandle shandle)
     Returns an array of strings representing Ids of packages that are loaded into engine.
 byte[]getPackageContent(WMSessionHandle shandle, String pkgId, String pkgVer)
     Returns the content of XPDL file containing package definition with the given Id and version as an array of bytes.
 WMEntitygetPackageEntity(WMSessionHandle shandle, String pkgId, String pkgVer)
     Returns the WMEntity representing package definition with the given Id and version. The package has to be loaded into shark engine.

If version parameter is an empty string or null, method returns the content of the current version of XPDL.
Parameters:
  pkgId - Id of package which XPDL file content has to be returned.
Parameters:
  pkgVer - The version of package which XPDL file content has to be returned.

 String[]getPackageVersions(WMSessionHandle shandle, String pkgId)
     Returns an array of strings representing versions of package with given Id that are loaded into engine.
 booleanisPackageOpened(WMSessionHandle shandle, String pkgId)
     Returns true if package with the given Id is loaded into engine.
Parameters:
  pkgId - Id of package to be tested if it is loaded into engine.
 booleanisPackageReferenced(WMSessionHandle shandle, String pkgId)
     Returns information if the current version of package with given id, that is loaded into engine, is referenced from other package (as an external package) that is also loaded into engine.
Parameters:
  pkgId - The Id of package we want to check if it is referenced.
 WMEntityopenPackage(WMSessionHandle shandle, String absolutePath)
     Allows administrator to load a package that is defined in XPDL file which path is given as a parameter.
 voidrefreshXPDLCache(WMSessionHandle shandle)
     Synchronizes XPDL caches with the repository state.
 voidsynchronizeXPDLCache(WMSessionHandle shandle)
     Synchronizes XPDL caches with the repository state.
 WMEntityupdatePackage(WMSessionHandle shandle, String id, byte[] schemaContent)
     Allows administrator to update a package that is loaded into shark and has the given id, with the package which XPDL representation is provided as a given byte[].
 WMEntityupdatePackageFromFile(WMSessionHandle shandle, String id, String absolutePathToNewPackage)
     Allows administrator to update a package that is loaded into shark and has the given id, with the package that can be found in XPDL file that is placed at given path. After successful update, every process that has already been instantiated from the process definitions contained within the package will continue its execution based on old definition, but one can instantiate processes based on new (updated) process definition.
Parameters:
  id - The id of package that is loaded into engine, and has to be updated.
Parameters:
  absolutePathToNewPackage - path of XPDL file containing the 'updater' package
throws:
  Exception - If something unexpected happens.
 WMEntityuploadPackage(WMSessionHandle shandle, byte[] schemaContent)
     Allows administrator to load a package that is defined as byte[] representation of Package's XPDL schema.
 WMEntityuploadPackages(WMSessionHandle shandle, byte[][] schemaContents)
     Allows administrator to load a packages that are defined as byte[] representation of Packages' XPDL schemas.



Method Detail
clearXPDLCache
void clearXPDLCache(WMSessionHandle shandle) throws Exception(Code)
Clears XPDL caches. After clearing caches, first time some XPDL instance is required, the cache is being filled with all instances that exist in DB.
throws:
  Exception - If something unexpected happens.



closeAllPackagesForId
WMEntityIterator closeAllPackagesForId(WMSessionHandle shandle, String id) throws Exception(Code)
Allows administrator to unload all package versions with the given id from shark. After successful unload, there will no longer be possible to instantiate processes from definitions that were contained within that package.
Parameters:
  id - The id of package that is loaded into engine, and has to be closed.
throws:
  Exception - If something unexpected happens. PackageInUse exception is thrownif this package is used by any other package that references it as anexternal package, and is also loaded into engine,PackageHasActiveProcesses is thrown if there are processes written ininstance persistence repository, that are instantiated from processdefinitions contained within package we want to unload.



closePackage
WMEntity closePackage(WMSessionHandle shandle, String id, String ver) throws Exception(Code)
Allows administrator to unload the package with the given id and given version from shark. After successful unload, there will no longer be possible to instantiate processes from definitions that were contained within that package.

If version parameter is an empty string or null, all the versions for the given id will be unloaded if possible (otherwise, exception will be thrown).
Parameters:
  id - The id of package that is loaded into engine, and has to be closed.
throws:
  Exception - If something unexpected happens. PackageInUse exception is thrownif this package is used by any other package that references it as anexternal package, and is also loaded into engine,PackageHasActiveProcesses is thrown if there are processes written ininstance persistence repository, that are instantiated from processdefinitions contained within package we want to unload.




getCurrentPackageVersion
String getCurrentPackageVersion(WMSessionHandle shandle, String pkgId) throws Exception(Code)
Returns the current version of the package.
Parameters:
  pkgId - Id of package which current version we want to know. the current package version
throws:
  Exception - If something unexpected happens.



getOpenedPackageIds
String[] getOpenedPackageIds(WMSessionHandle shandle) throws Exception(Code)
Returns an array of strings representing Ids of packages that are loaded into engine. Array of package Ids that are loaded into engine.
throws:
  Exception - If something unexpected happens.



getPackageContent
byte[] getPackageContent(WMSessionHandle shandle, String pkgId, String pkgVer) throws Exception(Code)
Returns the content of XPDL file containing package definition with the given Id and version as an array of bytes. The package has to be loaded into shark engine.

If version parameter is an empty string or null, method returns the content of the current version of XPDL.
Parameters:
  pkgId - Id of package which XPDL file content has to be returned.
Parameters:
  pkgVer - The version of package which XPDL file content has to be returned. Content of XPDL file.
throws:
  Exception - If something unexpected happens.




getPackageEntity
WMEntity getPackageEntity(WMSessionHandle shandle, String pkgId, String pkgVer) throws Exception(Code)
Returns the WMEntity representing package definition with the given Id and version. The package has to be loaded into shark engine.

If version parameter is an empty string or null, method returns the content of the current version of XPDL.
Parameters:
  pkgId - Id of package which XPDL file content has to be returned.
Parameters:
  pkgVer - The version of package which XPDL file content has to be returned. WMEntity representing XPDL file.
throws:
  Exception - If something unexpected happens.




getPackageVersions
String[] getPackageVersions(WMSessionHandle shandle, String pkgId) throws Exception(Code)
Returns an array of strings representing versions of package with given Id that are loaded into engine. Array of versions of package with given Id that are loaded into engine.
throws:
  Exception - If something unexpected happens.



isPackageOpened
boolean isPackageOpened(WMSessionHandle shandle, String pkgId) throws Exception(Code)
Returns true if package with the given Id is loaded into engine.
Parameters:
  pkgId - Id of package to be tested if it is loaded into engine. true if package with the given Id is loaded into engine, otherwuse false.
throws:
  Exception - If something unexpected happens.



isPackageReferenced
boolean isPackageReferenced(WMSessionHandle shandle, String pkgId) throws Exception(Code)
Returns information if the current version of package with given id, that is loaded into engine, is referenced from other package (as an external package) that is also loaded into engine.
Parameters:
  pkgId - The Id of package we want to check if it is referenced. true if package is referenced from other package, otherwise false.
throws:
  Exception - If something unexpected happens.



openPackage
WMEntity openPackage(WMSessionHandle shandle, String absolutePath) throws Exception(Code)
Allows administrator to load a package that is defined in XPDL file which path is given as a parameter. After the package is loaded into shark engine, the processes can be instantiated from process definitions that are contained within the package.
Parameters:
  absolutePath - path of package XPDL file to open The id of package that is going to be opened.
throws:
  Exception - If something unexpected happens. PackageInvalid exception isthrown if package that user wants to open hadn't passed shark'svalidation process and ExternalPackageInvalid is thrown if package thatuser wants to open has a external package, and this external packagehadn't passed shark's validation.



refreshXPDLCache
void refreshXPDLCache(WMSessionHandle shandle) throws Exception(Code)
Synchronizes XPDL caches with the repository state. It is supposed to be used in scenario when there are several VMs using shark, and when one of them loads new XPDL or updates existing.

It first clears all instances from the cache, and then checks for all XPDLs in repository, and loads them into cache.

Note: for better performance, use #synchronizeXPDLCache method.
throws:
  Exception - If something unexpected happens.




synchronizeXPDLCache
void synchronizeXPDLCache(WMSessionHandle shandle) throws Exception(Code)
Synchronizes XPDL caches with the repository state. It is supposed to be used in scenario when there are several VMs using shark, and when one of them loads new XPDL or updates existing.

It checks for all XPDLs in repository, and compares it against the cached ones, and determines which cached instances should be removed from cache permanently, which new instances should be loaded, and which old instances should be reloaded (because the change of their external package instance).
throws:
  Exception - If something unexpected happens.




updatePackage
WMEntity updatePackage(WMSessionHandle shandle, String id, byte[] schemaContent) throws Exception(Code)
Allows administrator to update a package that is loaded into shark and has the given id, with the package which XPDL representation is provided as a given byte[]. After successful update, every process that has already been instantiated from the process definitions contained within the package will continue its execution based on old definition, but one can instantiate processes based on new (updated) process definition.
Parameters:
  id - The id of package that is loaded into engine, and has to be updated.
Parameters:
  schemaContent - byte[] representation of XPDL schema defining a Package
throws:
  Exception - If something unexpected happens. PackageUpdateNotAllowed is thrownif package update is currently not allowed, PackageInvalid exception isthrown if package that user wants to open hadn't passed shark'svalidation process and ExternalPackageInvalid is thrown if package thatuser wants to open has a external package, and this external packagehadn't passed shark's validation.



updatePackageFromFile
WMEntity updatePackageFromFile(WMSessionHandle shandle, String id, String absolutePathToNewPackage) throws Exception(Code)
Allows administrator to update a package that is loaded into shark and has the given id, with the package that can be found in XPDL file that is placed at given path. After successful update, every process that has already been instantiated from the process definitions contained within the package will continue its execution based on old definition, but one can instantiate processes based on new (updated) process definition.
Parameters:
  id - The id of package that is loaded into engine, and has to be updated.
Parameters:
  absolutePathToNewPackage - path of XPDL file containing the 'updater' package
throws:
  Exception - If something unexpected happens. PackageUpdateNotAllowed is thrownif package update is currently not allowed, PackageInvalid exception isthrown if package that user wants to open hadn't passed shark'svalidation process and ExternalPackageInvalid is thrown if package thatuser wants to open has a external package, and this external packagehadn't passed shark's validation.



uploadPackage
WMEntity uploadPackage(WMSessionHandle shandle, byte[] schemaContent) throws Exception(Code)
Allows administrator to load a package that is defined as byte[] representation of Package's XPDL schema. After the package is loaded into shark engine, the processes can be instantiated from process definitions that are contained within the package.
Parameters:
  schemaContent - byte[] representation of the Package's XPDL schema The id of package that is going to be opened.
throws:
  Exception - If something unexpected happens. PackageInvalid exception isthrown if package that user wants to open hadn't passed shark'svalidation process and ExternalPackageInvalid is thrown if package thatuser wants to open has a external package, and this external packagehadn't passed shark's validation.



uploadPackages
WMEntity uploadPackages(WMSessionHandle shandle, byte[][] schemaContents) throws Exception(Code)
Allows administrator to load a packages that are defined as byte[] representation of Packages' XPDL schemas. After the package is loaded into shark engine, the processes can be instantiated from process definitions that are contained within the package.
Parameters:
  schemaContents - List of byte[] representation of the Packages' XPDL schemas The id of the main package that is going to be opened.
throws:
  Exception - If something unexpected happens. PackageInvalid exception isthrown if package that user wants to open hadn't passed shark'svalidation process and ExternalPackageInvalid is thrown if package thatuser wants to open has a external package, and this external packagehadn't passed shark's validation.



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.