Fire up your applications with Jazz
RSS
Jazz CMS Wiki

About Us

CMS CMS Administration GUI Jazz Jazz Administration Jazz Web Parts Library misc Roles Solutions Training Web Parts Web Service Website Design Website Procedures Wiki conventions WordML Workflow Administration

Quick Search
»
Advanced Search »

Web Service: Code Classes

RSS
Modified on 2011/10/06 19:42 by Charles Categorized as Web Service

Table of Contents [Hide/Show]


Code Classes for the Jetfire Web Service

This section examines the web methods used to explore code classes found in the Nexus and to add Jetfire code to the Nexus.


Get Jetfire Code

This method retrieves the Jetfire code that implements the class.

Prerequisites: Must be logged in.
Send:
  • The Nexus Key received during login
  • The name of the class requested

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <GetJetfireCode xmlns="http://Jetfire.ca/WebService">
      <nexusKey>string</nexusKey>
      <className>string</className>
    </GetJetfireCode>
  </soap:Body>
</soap:Envelope>

Receive: This example shows the Jetfire code for the UserLogin class. If the requested workflow class does not exist, an error message is received (see below the success response).
<?xml version='1.0' encoding='utf-8' ?>
<JetfireCodeFiles xmlns="http://schemas.Jetfire.ca/JetfireCodeFiles">
  <JetfireCodeFile Code="
    namespace System 
    {
	public workflow UserLogin : User
	{
		public UserLogin(string name) : base(name)
		{ 
			CreateDateTime = DateTime.Now;
		} 
		public UserLogin(string name, Profile profile) : base(name, profile)
		{ 
			CreateDateTime = DateTime.Now;
		} 
		// Add Properties 
		public string Password
		{
<-- snip -->
		} 
		public bool IsApproved
		{
			get;
			set; 
		} 
	} 
}"/>
</JetfireCodeFiles>

Failure case:

<?xml version='1.0' encoding='utf-8' ?>
<Errors xmlns="http://schemas.Jetfire.ca/Errors">
  <Error Name="Error 1" Value="Cannot find Workflow Class: RequestedWorkflowName"/>
</Errors>

Jetfire Code Library

This method returns a list of Jetfire code files that are available.

Prerequisites: None.
Send:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <JetfireCodeLibary xmlns="http://Jetfire.ca/WebService" />
  </soap:Body>
</soap:Envelope>

Receive: This is an xml string that contains a list of Jetfire code files.
<?xml version="1.0" encoding="utf-8"?>
<Jetfire>
	<CodeFiles Comment="Comments about the CodeFile Element. Name: MUST be a class included in the file.  DisplayName is displayed to the user. Comment is a description that is displayed to the user.Path is the virtual path to the Code File. ClassDependencies is a list of Class Elements that refer to the dependencies by Name in this file.">
		<CodeFile Name="BusinessEvent" DisplayName="Business Event" Comment="Jetfire Apps: TON (the Ottawa Network) Business Events" ClassName="JetfireApps.BusinessEvent" RequiredRoles="" Path="TrackerRealm.WebBase.Apps.BusinessEvents.txt"></CodeFile>
		<CodeFile Name="CalendarEvent" DisplayName="Calendar Event" Comment="Jetfire Apps: Calendar Events" ClassName="JetfireApps.CalendarEvent" RequiredRoles="" Path="TrackerRealm.WebBase.Apps.CalendarEvent.txt">
			<ClassDependencies>
				<Class>TimePeriod</Class>
				<Class>RadColor</Class>
			</ClassDependencies>
		</CodeFile>
		<CodeFile Name="NewsItem" ClassName="JetfireApps.NewsItem" DisplayName="News Item" Comment="Jetfire Apps: News" Path="TrackerRealm.WebBase.Apps.News.txt">
			<ClassDependencies>
				<Class>Standard</Class>
			</ClassDependencies>
		</CodeFile>
		<CodeFile Name="Newsletter" DisplayName="Newsletter" Comment="Jetfire Applications: Newsletter" ClassName="JetfireApps.Newsletter" RequiredRoles="" Path="TrackerRealm.WebBase.Apps.Newsletter.txt">
			<ClassDependencies>
				<Class>Standard</Class>
				<Class>Subscribed_User</Class>
			</ClassDependencies>
		</CodeFile>
<-- snip -->
	</CodeFiles>
</Jetfire>

Get Code Classes

This method retrieves the code classes from the Nexus.

Prerequisites: Must be logged in.
Send: the Nexus Key received during login.

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <GetCodeClasses xmlns="http://Jetfire.ca/WebService">
      <nexusKey>string</nexusKey>
    </GetCodeClasses>
  </soap:Body>
</soap:Envelope>

Receive: an xml-formatted string that contains the definition for all workflow classes.
<?xml version='1.0' encoding='utf-8' ?>
<WorkflowClasses>
	<WorkflowClass Name="Email" Guid="f0e3ac7c-3b67-4a53-a1df-f82f39082f30">
		<Properties>
			<Property Name="Guid" Value="" Label="Guid" ToolTip="Guid" Display="False" FormElement="Label" ClassName="plainString" Group="" Position="0"/>
			<Property Name="ToolTip" Value="" Label="ToolTip" ToolTip="ToolTip" Display="False" FormElement="TextBox" ClassName="string" Group="" Position="1"/>
			<Property Name="Workspace" Value="" Label="Workspace" ToolTip="Workspace" Display="False" FormElement="Label" ClassName="workspace" Group="" Position="2"/>
			<Property Name="Subject" Value="" Label="Subject" ToolTip="Subject" Display="False" FormElement="TextBox" ClassName="string" Group="" Position="3"/>
			<Property Name="WorkflowClass" Value="" Label="WorkflowClass" ToolTip="WorkflowClass" Display="False" FormElement="Label" ClassName="plainString" Group="" Position="4"/>
			<Property Name="CurrentState" Value="" Label="CurrentState" ToolTip="CurrentState" Display="False" FormElement="Label" ClassName="plainString" Group="" Position="5"/>
		</Properties>
		<Methods></Methods>
	</WorkflowClass>
	<WorkflowClass Name="OawaContact" Guid="ff3fd176-931d-4ff3-baf6-df24f0477e63">
		<Properties>
			<Property Name="Subject" Value="" Label="Name" ToolTip="" Display="True" FormElement="Label" ClassName="string" Group="" Position="1"/>
			<Property Name="FirstName" Value="" Label="First Name" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="2"/>
			<Property Name="LastName" Value="" Label="Last Name" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="3"/>
			<Property Name="Club" Value="" Label="Club" ToolTip="" Display="True" FormElement="Label" ClassName="OawaClub" Group="OawaClub" Position="4"/>
			<Property Name="LastUpdate" Value="" Label="Last Update" ToolTip="" Display="True" FormElement="Label" ClassName="DateTime" Group="" Position="5"/>
			<Property Name="DOB" Value="" Label="Date of Birth" ToolTip="" Display="True" FormElement="BirthDate" ClassName="Date" Group="" Position="10"/>
			<Property Name="Rate" Value="" Label="Division" ToolTip="" Display="True" FormElement="DropDownList" ClassName="OawaRate" Group="" Position="11"/>
			<Property Name="Gender" Value="" Label="Gender" ToolTip="" Display="True" FormElement="Choice" ClassName="Gender" Group="" Position="17"/>
			<Property Name="HomeAddress1" Value="" Label="Address 1" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="74"/>
			<Property Name="HomeCity" Value="" Label="City" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="76"/>
			<Property Name="HomeProvince" Value="" Label="Province" ToolTip="" Display="True" FormElement="DropDownList" ClassName="Province" Group="Province" Position="77"/>
			<Property Name="HomePC" Value="" Label="Postal Code" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="78"/>
			<Property Name="HomeEmail" Value="" Label="Email Address" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="88"/>
			<Property Name="HomePhone" Value="" Label="Phone" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="91"/>
			<Property Name="BusinessPhone" Value="" Label="Alternate Phone" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="92"/>
			<Property Name="FaxPhone" Value="" Label="Fax Number" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="93"/>
			<Property Name="ParentEmail" Value="" Label="Parent Email Address" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="97"/>
			<Property Name="ParentPhone" Value="" Label="Parent Phone" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="98"/>
			<Property Name="OnCoachesMailingList" Value="" Label="On Mailing List" ToolTip="" Display="True" FormElement="Bool" ClassName="bool" Group="" Position="100"/>
			<Property Name="Payments" Value="" Label="Payments" ToolTip="" Display="True" FormElement="Collection" ClassName="List" Group="" Position="102"/>
			<Property Name="Notes" Value="" Label="Notes" ToolTip="" Display="True" FormElement="Collection" ClassName="List" Group="" Position="103"/>
			<Property Name="OawaNumber" Value="" Label="Oawa Number" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="111"/>
			<Property Name="OawaCardNumber" Value="" Label="Oawa Card Number" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="112"/>
			<Property Name="MembershipDate" Value="" Label="Membership Date" ToolTip="" Display="True" FormElement="DateControl" ClassName="Date" Group="" Position="114"/>
		</Properties>
		<Methods>
			<Method Name="AddWrestlerProfile" Label="Add Wrestler Profile" ToolTip="" Display="True" Position="1"/>
			<Method Name="AddCoachProfile" Label="Add Coach Profile" ToolTip="" Display="True" Position="2"/>
			<Method Name="AddGrapplerProfile" Label="Add Grappler Profile" ToolTip="" Display="True" Position="2"/>
			<Method Name="AddOfficialProfile" Label="Add Official Profile" ToolTip="" Display="True" Position="3"/>
			<Method Name="AddStaffProfile" Label="Add Staff Profile" ToolTip="" Display="True" Position="4"/>
			<Method Name="AddBoardProfile" Label="Add Board Profile" ToolTip="" Display="True" Position="6"/>
			<Method Name="AddPayment" Label="Add Payment" ToolTip="" Display="True" Position="11"/>
			<Method Name="AddNote" Label="Add Note" ToolTip="" Display="True" Position="21"/>
			<Method Name="Delete_Member" Label="Delete" ToolTip="" Display="True" Position="22"/>
			<Method Name="RenewClubMembership" Label="Renew Club Membership" ToolTip="" Display="True" Position="31"/>
			<Method Name="ClubRegistered" Label="Member accepted into Club" ToolTip="" Display="True" Position="32"/>
			<Method Name="PaidClub" Label="Paid Fees" ToolTip="" Display="True" Position="33"/>
			<Method Name="RenewOawaMembership" Label="Request OAWA Membership" ToolTip="" Display="True" Position="34"/>
			<Method Name="OawaRegistered" Label="Member accepted into OAWA" ToolTip="" Display="True" Position="35"/>
			<Method Name="PaidOawa" Label="Paid Oawa Fees" ToolTip="" Display="True" Position="36"/>
			<Method Name="Set_Inactive" Label="Mark Inactive" ToolTip="" Display="True" Position="37"/>
			<Method Name="Set_Active" Label="Mark Active" ToolTip="" Display="True" Position="38"/>
			<Method Name="ResetContact" Label="Reset Status" ToolTip="Resets the status of the member to Renew Club Membership" Display="True" Position="39"/>
		</Methods>
	</WorkflowClass>
	<WorkflowClass Name="WrestlerProfile" Guid="06686b3c-b157-4e81-9066-fe4d3419bb58">
		<Properties>
			<Property Name="HasSignature" Value="" Label="Signature?" ToolTip="" Display="True" FormElement="Bool" ClassName="bool" Group="" Position="11"/>
			<Property Name="DOBProofConfirmed" Value="" Label="Confirmed DoB?" ToolTip="" Display="True" FormElement="Bool" ClassName="bool" Group="" Position="12"/>
			<Property Name="DOBProof" Value="" Label="Proof DoB" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="13"/>
			<Property Name="WeightClass" Value="" Label="Weight Class" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="15"/>
			<Property Name="Division" Value="" Label="Division" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="17"/>
		</Properties>
		<Methods></Methods>
	</WorkflowClass>
<--- snip -->
</WorkflowClasses>

Namespaces

This method retrieves an xml definition of all workflow classes organized by namespace.

Prerequisites: Must be logged in.
Send:
  • The Nexus Key received during login

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <Namespaces xmlns="http://Jetfire.ca/WebService">
      <nexusKey>string</nexusKey>
    </Namespaces>
  </soap:Body>
</soap:Envelope>

Receive:

<?xml version='1.0' encoding='utf-8' ?>
<Namespaces xmlns="http://schemas.Jetfire.ca/Namespaces">
	<Namespace Name="Workflow">
		<WorkflowClasses>
			<WorkflowClass Name="Email" Guid="5b78ea40-6bc8-415d-a6f2-9553d231b781">
				<Properties>
					<Property Name="Guid" Value="" Label="Guid" ToolTip="Guid" Display="False" FormElement="Label" ClassName="plainString" Group="" Position="0"/>
					<Property Name="ToolTip" Value="" Label="ToolTip" ToolTip="ToolTip" Display="False" FormElement="TextBox" ClassName="string" Group="" Position="1"/>
					<Property Name="Workspace" Value="" Label="Workspace" ToolTip="Workspace" Display="False" FormElement="Label" ClassName="workspace" Group="" Position="2"/>
					<Property Name="Subject" Value="" Label="Subject" ToolTip="Subject" Display="False" FormElement="TextBox" ClassName="string" Group="" Position="3"/>
					<Property Name="WorkflowClass" Value="" Label="WorkflowClass" ToolTip="WorkflowClass" Display="False" FormElement="Label" ClassName="plainString" Group="" Position="4"/>
					<Property Name="CurrentState" Value="" Label="CurrentState" ToolTip="CurrentState" Display="False" FormElement="Label" ClassName="plainString" Group="" Position="5"/>
				</Properties>
				<Methods></Methods>
			</WorkflowClass>
		</WorkflowClasses>
	</Namespace>
	<Namespace Name="JetfireContacts">
		<WorkflowClasses>
			<WorkflowClass Name="Address" Guid="1574a684-5168-4d90-a23a-57af91ae1c1c">
<-- snip -->
			</WorkflowClass>
		<WorkflowClasses>
	</Namespace>
</Namespaces>

Parse Jetfire Code

This method retrieves the Jetfire code that implements the class.

Prerequisites: Must be logged in.
Send:
  • The Nexus Key received during login
  • The Jetfire code to be parsed
  • an optional Parse Unit Guid. If this is new Jetfire code being added to the Nexus, then the puGuid is blank. If this is Jetfire code that is being upgraded, then the puGuid for the existing Workflow Class must be supplied.

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <ParseJetfireCode xmlns="http://Jetfire.ca/WebService">
      <nexusKey>string</nexusKey>
      <code>string</code>
      <puGuid>string</puGuid>
    </ParseJetfireCode>
  </soap:Body>
</soap:Envelope>

Receive: This example response is the success path. If there is a problem adding the code to the Nexus, the error element will contain an error.

<?xml version='1.0' encoding='utf-8' ?>
<Errors xmlns="http://schemas.Jetfire.ca/Errors">
  <Error Name="Error 1" Value="Code is added"/>
</Errors>

Verify Workflow Class

This method retrieves the Jetfire code that implements the class.

Prerequisites: Must be logged in.
Send:
  • The Nexus Key received during login
  • The name of the class to be verified

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <VerifyWorkflowClass xmlns="http://Jetfire.ca/WebService">
      <nexusKey>string</nexusKey>
      <wClass>string</wClass>
    </VerifyWorkflowClass>
  </soap:Body>
</soap:Envelope>

Receive: The example response shows the success path. If the Workflow class not exist, then the error message shows "WorkflowClass name not found".

<?xml version='1.0' encoding='utf-8' ?>
<Errors xmlns="http://schemas.Jetfire.ca/Errors">
  <Error Name="Error 1" Value="true"/>
</Errors>

Workflow Class

This method retrieves the Jetfire code that implements the class.

Prerequisites: Must be logged in.
Send:
  • The Nexus Key received during login
  • The name of the class requested

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <WorkflowClass xmlns="http://Jetfire.ca/WebService">
      <nexusKey>string</nexusKey>
      <workflowName>string</workflowName>
    </WorkflowClass>
  </soap:Body>
</soap:Envelope>

Receive: an xml string that defines the properties and methods for the requested workflow class. the following xml string shows the success path. The failure case is shown below.

<?xml version='1.0' encoding='utf-8' ?>
<WorkflowClasses>
	<WorkflowClass Name="UserLogin" Guid="3acf2285-7e1f-4bcd-89e2-ab369c753a68">
		<Properties>
			<Property Name="Name" Value="" Label="Login ID" ToolTip="The Login ID used to login" Display="True" FormElement="Label" ClassName="plainString" Group="" Position="1"/>
<-- snip -->
		</Properties>
		<Methods></Methods>
	</WorkflowClass>
</WorkflowClasses>

Failure case:

<?xml version='1.0' encoding='utf-8' ?>
<Errors xmlns="http://schemas.Jetfire.ca/Errors">
  <Error Name="Error 1" Value="Cannot find Workflow Class: RequestedWorkflowName"/>
</Errors>

Workflow Classes

This method retrieves the Workflow classes from the Nexus.

Prerequisites: Must be logged in.
Send:
  • The Nexus Key received during login

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <WorkflowClasses xmlns="http://Jetfire.ca/WebService">
      <nexusKey>string</nexusKey>
    </WorkflowClasses>
  </soap:Body>
</soap:Envelope>

Receive:

<?xml version='1.0' encoding='utf-8' ?>
<WorkflowClasses>
	<WorkflowClass Name="Address" Guid="1574a684-5168-4d90-a23a-57af91ae1c1c">
		<Properties>
			<Property Name="Address1" Value="" Label="Line 1" ToolTip="" Display="True" FormElement="TextBox" ClassName="string" Group="" Position="11"/>
<-- snip -->
</WorkflowClasses>

http://www.wiebeworks.com - Wiki version 3.0.4.560.