|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.alarmpoint.servicemanager.ServiceManagerScriptObject
public class ServiceManagerScriptObject
Interfaces with the Service Manager SOAP web service in order to query, create and update records.
Constructor Summary | |
---|---|
ServiceManagerScriptObject()
Construct a uninitialized object. |
|
ServiceManagerScriptObject(java.lang.String url,
java.lang.String user,
java.lang.String password)
Construct a new ServiceManagerScriptObject with the specified url and user/password combination |
Method Summary | |
---|---|
void |
closeIncident(java.lang.String incidentId,
org.dom4j.Element instance)
Close the Service Manager incident identified by the incidentID with the specified instance |
void |
closeIncident(java.lang.String incidentId,
java.util.Map<java.lang.String,java.lang.Object> fields)
Close the Service Manager incident identified by the incidentID with the specified fields and values |
void |
closeIncident(java.lang.String incidentId,
java.lang.String resolution,
java.lang.String fixType)
Close the Service Manager incident identified by the incidentID with a resolution |
java.lang.String |
createIncident(org.dom4j.Element instance)
Create a new Service Manager incident with the specified instance |
java.lang.String |
createIncident(java.util.Map<java.lang.String,java.lang.Object> fields)
Create a new Service Manager incident with the specified fields and values |
java.util.Map<java.lang.String,java.util.Collection<java.lang.String>> |
getGroupedList(java.lang.String operation,
java.lang.String queryString,
java.lang.String valueElement,
java.lang.String groupElement)
Retrive a list of strings from Service Manager and group them based on a field on that object |
java.util.SortedSet<java.lang.String> |
getSortedList(java.lang.String operation,
java.lang.String queryString,
java.lang.String elementName)
Retrive a list of strings from Service Manager |
java.util.Collection<java.util.Map<java.lang.String,java.lang.String>> |
getValueMap(java.lang.String operation,
java.lang.String queryString)
Retrive a list of all fields and values from Service Manager for a specified object |
void |
initializeClient(java.lang.String url,
java.lang.String user,
java.lang.String password)
Initialize this class with the specified url and user/password combination |
java.util.SortedSet<java.lang.String> |
queryCategoryList()
Retrieve the list of active categories from Service Manager |
java.util.List<ServiceManagerIncident> |
queryIncident(ServiceManagerQuery query)
Retrieve a list of incidents from Service Manager |
java.util.List<ServiceManagerIncident> |
queryIncident(java.lang.String queryString)
Retrieve a list of incidents from Service Manager |
java.util.SortedSet<java.lang.String> |
queryProblemTypeList()
Retrieve the list of active problem types from Service Manager |
java.util.SortedSet<java.lang.String> |
queryProductTypeList()
Retrieve the list of active product types from Service Manager |
java.util.SortedSet<java.lang.String> |
querySubcategoryList()
Retrieve the list of active subcategories from Service Manager |
void |
resolveIncident(java.lang.String incidentId,
org.dom4j.Element instance)
Resolve the Service Manager incident identified by the incidentID with the specified instance |
void |
resolveIncident(java.lang.String incidentId,
java.lang.String resolution,
java.lang.String fixType,
java.lang.String message,
java.lang.String closureCode)
Resolve the Service Manager incident identified by the incidentID with the specified fields and values |
org.dom4j.Node |
sendReceive(java.lang.String action,
org.dom4j.Element payload)
Send a SOAP request to the Service Manager server and return the contents ot the returned SOAP body |
void |
updateIncident(java.lang.String incidentId,
org.dom4j.Element instance)
Update the Service Manager incident identified by the incidentID with the specified instance |
void |
updateIncident(java.lang.String incidentId,
java.util.Map<java.lang.String,java.lang.Object> fields)
Update the Service Manager incident identified by the incidentID with the specified fields and values |
void |
updateIncident(java.lang.String incidentId,
java.lang.String message)
Update the Service Manager incident identified by the incidentID with a journal update |
void |
updateIncident(java.lang.String incidentId,
java.lang.String message,
java.lang.String status)
Update the Service Manager incident identified by the incidentID with a journal update and status |
void |
updateIncident(java.lang.String incidentId,
java.lang.String message,
java.lang.String status,
java.lang.String assignee)
Update the Service Manager incident identified by the incidentID with a journal update, status and assignee |
java.lang.String |
validateCredentials(java.lang.String operation)
Given a List Operation this method will return null if the intialized credentials are valid and a string detailing the error otherwise |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ServiceManagerScriptObject()
public ServiceManagerScriptObject(java.lang.String url, java.lang.String user, java.lang.String password)
url
- The url of the Service Manager web servicesuser
- The username to use for the Service Manager web servicespassword
- The password to use for the Service Manager web servicesMethod Detail |
---|
public void initializeClient(java.lang.String url, java.lang.String user, java.lang.String password)
url
- the url of the Service Manager web servicesuser
- the user for the Service Manager web servicespassword
- the password for the Service Manager web servicespublic java.lang.String createIncident(java.util.Map<java.lang.String,java.lang.Object> fields) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
fields
- The Map used to construct the instance XML element
ServiceManagerException
- if a error occurs with a message detailing that errorpublic java.lang.String createIncident(org.dom4j.Element instance) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
instance
- the XML instance element for the create request
ServiceManagerException
- if a error occurs with a message detailing that errorpublic void updateIncident(java.lang.String incidentId, java.lang.String message) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false update.action field must have the JournalUpdates API Caption and Exclude false
incidentId
- incident id identifying the incident to updatemessage
- The message to be added to the JournalUpdates
ServiceManagerException
- if the update was not successfulpublic void updateIncident(java.lang.String incidentId, java.lang.String message, java.lang.String status) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false update.action field must have the JournalUpdates API Caption and Exclude false problem.status field must have the IMTicketStatus API Caption and Exclude false
incidentId
- incident id identifying the incident to updatemessage
- The message to be added to the JournalUpdatesstatus
- The status to update the incident with
ServiceManagerException
- if the update was not successfulpublic void updateIncident(java.lang.String incidentId, java.lang.String message, java.lang.String status, java.lang.String assignee) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false update.action field must have the JournalUpdates API Caption and Exclude false problem.status field must have the IMTicketStatus API Caption and Exclude false assignee.name field must have the AssigneeName API Caption and Exclude false
incidentId
- incident id identifying the incident to updatemessage
- The message to be added to the JournalUpdatesstatus
- The status to update the incident withassignee
- The assignee to update the incident with
ServiceManagerException
- if the update was not successfulpublic void updateIncident(java.lang.String incidentId, java.util.Map<java.lang.String,java.lang.Object> fields) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
incidentId
- incident id identifying the incident to updatefields
- The Map used to construct the instance XML element
ServiceManagerException
- if a error occurs with a message detailing that errorpublic void updateIncident(java.lang.String incidentId, org.dom4j.Element instance) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
incidentId
- incident id identifying the incident to updateinstance
- the XML instance element for the update request
ServiceManagerException
- if a error occurs with a message detailing that errorpublic void resolveIncident(java.lang.String incidentId, java.lang.String resolution, java.lang.String fixType, java.lang.String message, java.lang.String closureCode) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
incidentId
- incident id identifying the incident to resolveresolution
- String containing the text detailing the resolution codefixType
- type of fix being appliedmessage
- additional informationclosureCode
- String containing the code that will be displayed in SM indicating the closure reason.
ServiceManagerException
- if a error occurs with a message detailing that errorpublic void resolveIncident(java.lang.String incidentId, org.dom4j.Element instance) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
incidentId
- incident id identifying the incident to resolveinstance
- the XML instance element for the resolve request
ServiceManagerException
- if a error occurs with a message detailing that errorpublic void closeIncident(java.lang.String incidentId, java.lang.String resolution, java.lang.String fixType) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false resolution field must have the Resolution API Caption and Exclude false
incidentId
- incident id identifying the incident to closeresolution
- The message to be added to the ResolutionfixType
- Temporary or Permanent
ServiceManagerException
- if the update was not successfulpublic void closeIncident(java.lang.String incidentId, java.util.Map<java.lang.String,java.lang.Object> fields) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
incidentId
- incident id identifying the incident to closefields
- The Map used to construct the instance XML element
ServiceManagerException
- if a error occurs with a message detailing that errorpublic void closeIncident(java.lang.String incidentId, org.dom4j.Element instance) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident Data Policy: number field must have the IncidentID API Caption and Exclude false
incidentId
- incident id identifying the incident to closeinstance
- the XML instance element for the close request
ServiceManagerException
- if a error occurs with a message detailing that errorpublic java.util.List<ServiceManagerIncident> queryIncident(ServiceManagerQuery query) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident
query
- A ServiceManagerQuery
object used to construct the Service Manager query
ServiceManagerIncident
objects representing the incidents retrieved from Service
Manager
ServiceManagerException
- if a error occurs with a message detailing that errorpublic java.util.List<ServiceManagerIncident> queryIncident(java.lang.String queryString) throws ServiceManagerException
Note: This method assumes that a extaccess record exists with the following values: Name: probsummary Object Name: Incident
queryString
- The search query passed to Service Manager
ServiceManagerIncident
objects representing the incidents retrieved from Service
Manager
ServiceManagerException
- if a error occurs with a message detailing that errorpublic java.util.SortedSet<java.lang.String> queryCategoryList()
Note: This method assumes that a extaccess record exists with the following values: Name: category Object Name: Category Data Policy: name field must have the name API Caption and Exclude false
public java.util.SortedSet<java.lang.String> querySubcategoryList()
Note: This method assumes that a extaccess record exists with the following values: Name: subcategory Object Name: Subcategory Data Policy: subcategory field must have the subcategory API Caption and Exclude false
public java.util.SortedSet<java.lang.String> queryProblemTypeList()
Note: This method assumes that a extaccess record exists with the following values: Name: problemtype Object Name: ProblemType Data Policy: problem.type field must have the problem.type API Caption and Exclude false
public java.util.SortedSet<java.lang.String> queryProductTypeList()
Note: This method assumes that a extaccess record exists with the following values: Name: producttype Object Name: ProductType Data Policy: product.type field must have the product.type API Caption and Exclude false
public java.util.SortedSet<java.lang.String> getSortedList(java.lang.String operation, java.lang.String queryString, java.lang.String elementName) throws ServiceManagerException
operation
- The name of the root element of the request ("RetrieveCategoryListRequest" for example)queryString
- The query used to select the valueselementName
- the API Caption of the field to return the values for
ServiceManagerException
- if a error occurs with a message detailing that errorpublic java.util.Collection<java.util.Map<java.lang.String,java.lang.String>> getValueMap(java.lang.String operation, java.lang.String queryString) throws ServiceManagerException
operation
- The name of the root element of the request ("RetrieveCategoryListRequest" for example)queryString
- The query used to select the values
ServiceManagerException
- if a error occurs with a message detailing that errorpublic java.util.Map<java.lang.String,java.util.Collection<java.lang.String>> getGroupedList(java.lang.String operation, java.lang.String queryString, java.lang.String valueElement, java.lang.String groupElement) throws ServiceManagerException
operation
- The name of the root element of the request ("RetrieveCategoryListRequest" for example)queryString
- The query used to select the valuesvalueElement
- the API Caption of the field to return the values forgroupElement
- the API Caption of the field to group the returned values by
ServiceManagerException
- if a error occurs with a message detailing that errorpublic java.lang.String validateCredentials(java.lang.String operation) throws ServiceManagerException
operation
- The name of the root element of the request ("RetrieveCategoryListRequest" for example)
ServiceManagerException
- if a error occurs with a message detailing that errorpublic org.dom4j.Node sendReceive(java.lang.String action, org.dom4j.Element payload) throws ServiceManagerException
action
- The SOAP Action to perform in Service Manager. The possible values are defined on the extaccess
tablepayload
- A dom4j Element that will be the payload of the SOAP request
ServiceManagerException
- if a error occurs with a message detailing that error
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |