Package dev.galasa.cicsts
Interface ICemt
public interface ICemt
-
Method Summary
Modifier and TypeMethodDescriptionvoiddiscardResource(@NotNull ICicsTerminal cemtTerminal, @NotNull String resourceType, @NotNull String resourceName) Discards a specified resource and throws an exception if the specified search text is not found on the terminal.inquireResource(@NotNull ICicsTerminal cemtTerminal, @NotNull String resourceType, @NotNull String resourceName) Inquire a CEMT resource using the resource type and name.booleaninquireResource(@NotNull ICicsTerminal cemtTerminal, @NotNull String resourceType, @NotNull String resourceName, @NotNull String searchText) Inquire a CEMT resource using the resource type and name.booleaninquireResourceNotFound(ICicsTerminal terminal, String resourceType, String resourceName, String searchText) Does a CEMT Inquire and expects it to be NOTFOUND.booleaninquireResourceNotFound(ICicsTerminal terminal, String resourceType, String resourceName, String searchText, String state) Does a CEMT Inquire and expects it to be NOTFOUND.booleanisResourceEnabled(ICicsTerminal terminal, String resourceType, String resourceName) Does a CEMT Inquire and expects it to be ENABLED.booleanperformSystemProperty(@NotNull ICicsTerminal cemtTerminal, @NotNull String systemArea, @NotNull String setRequest, @NotNull String expectedResponse) setResource(@NotNull ICicsTerminal cemtTerminal, @NotNull String resourceType, String resourceName, @NotNull String action) Set the state of a CEMT resource using the resource type and name.voidwaitForDisabledResource(ICicsTerminal terminal, String resourceType, String resourceName) Wait for a CICS resource to become disabled.voidwaitForDisabledResource(ICicsTerminal terminal, String resourceType, String resourceName, long defaultResourceTimeoutMilliseconds) Wait for a CICS resource to become disabled.voidwaitForEnabledResource(ICicsTerminal terminal, String resourceType, String resourceName) See#waitForEnabledResource(ITerminal, String, String, int)for explanation, the default resource timeout is used.voidwaitForEnabledResource(ICicsTerminal terminal, String resourceType, String resourceName, long defaultResourceTimeoutMilliseconds) Wait for a CICS resource to become enabled.
-
Method Details
-
inquireResource
CicstsHashMap inquireResource(@NotNull @NotNull ICicsTerminal cemtTerminal, @NotNull @NotNull String resourceType, @NotNull @NotNull String resourceName) throws CemtException Inquire a CEMT resource using the resource type and name. This does not support inquiries of multiple resources at once.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status. For example, the test could first issueCEOT TRANIDONLYresourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.- Returns:
- null if the resource is not found.
- Throws:
CemtException
-
inquireResource
boolean inquireResource(@NotNull @NotNull ICicsTerminal cemtTerminal, @NotNull @NotNull String resourceType, @NotNull @NotNull String resourceName, @NotNull @NotNull String searchText) throws CemtException Inquire a CEMT resource using the resource type and name. This methods searches the text and give the response back as boolean value (true/false).- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.searchText-- Returns:
- boolean value
- Throws:
CemtException
-
waitForDisabledResource
void waitForDisabledResource(ICicsTerminal terminal, String resourceType, String resourceName, long defaultResourceTimeoutMilliseconds) throws CemtException Wait for a CICS resource to become disabled. This method will issue a CEMT INQUIRE every 500ms for as long as the resourceTimeout parameter specifies. This method looks for "Dis" to indicate the resource is disabled.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.defaultResourceTimeoutMilliseconds- The timeout in milliseconds.- Throws:
CemtException
-
waitForEnabledResource
void waitForEnabledResource(ICicsTerminal terminal, String resourceType, String resourceName) throws CemtException See#waitForEnabledResource(ITerminal, String, String, int)for explanation, the default resource timeout is used.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.- Throws:
CEMTExceptionCemtException
-
waitForEnabledResource
void waitForEnabledResource(ICicsTerminal terminal, String resourceType, String resourceName, long defaultResourceTimeoutMilliseconds) throws CemtException Wait for a CICS resource to become enabled. This method will issue a CEMT INQUIRE every 500ms for as long as the resourceTimeout parameter specifies. This method looks for " Ena " to indicate the resource is enabled.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.defaultResourceTimeoutMilliseconds- The timeout in milliseconds.- Throws:
CEMTExceptionCemtException
-
setResource
CicstsHashMap setResource(@NotNull @NotNull ICicsTerminal cemtTerminal, @NotNull @NotNull String resourceType, String resourceName, @NotNull @NotNull String action) throws CemtException Set the state of a CEMT resource using the resource type and name.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status. For example, the test could first issueCEOT TRANIDONLYresourceType- aStringof the type of resource you want to set.resourceName- aStringof the name of the resource you want to set. Can benullfor exampleSET DB2CONN ....action- aStringof the action you want to perform on the resource.- Returns:
- a
CicstsHashMapobject containing all of the properties of the resource. - Throws:
CemtException
-
discardResource
void discardResource(@NotNull @NotNull ICicsTerminal cemtTerminal, @NotNull @NotNull String resourceType, @NotNull @NotNull String resourceName) throws CemtException Discards a specified resource and throws an exception if the specified search text is not found on the terminal.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status. For example, the test could first issueCEOT TRANIDONLYresourceType- aStringof the type of resource you want to discard.resourceName- aStringof the name of the resource you want to discard.- Throws:
CemtException
-
performSystemProperty
boolean performSystemProperty(@NotNull @NotNull ICicsTerminal cemtTerminal, @NotNull @NotNull String systemArea, @NotNull @NotNull String setRequest, @NotNull @NotNull String expectedResponse) throws CemtException - Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status. For example, the test could first issueCEOT TRANIDONLYsystemArea- aStringthe specifies the system area.setRequest-expectedResponse-- Returns:
- boolean
- Throws:
CemtException
-
inquireResourceNotFound
boolean inquireResourceNotFound(ICicsTerminal terminal, String resourceType, String resourceName, String searchText) throws CemtException Does a CEMT Inquire and expects it to be NOTFOUND.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.searchText- - text to be searched on terminal- Throws:
CemtException- - throws when error occurs in the CEMT transaction
-
inquireResourceNotFound
boolean inquireResourceNotFound(ICicsTerminal terminal, String resourceType, String resourceName, String searchText, String state) throws CemtException Does a CEMT Inquire and expects it to be NOTFOUND.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.searchText- - text to be searched on terminalstate- - the status of the resource- Throws:
CemtException- -throws when error occurs in the CEMT transaction
-
waitForDisabledResource
void waitForDisabledResource(ICicsTerminal terminal, String resourceType, String resourceName) throws CemtException Wait for a CICS resource to become disabled. This method will issue a CEMT INQUIRE . This method looks for "Dis" to indicate the resource is disabled.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.- Throws:
CemtException- - throws when error occurs in the CEMT transaction.
-
isResourceEnabled
boolean isResourceEnabled(ICicsTerminal terminal, String resourceType, String resourceName) throws CemtException Does a CEMT Inquire and expects it to be ENABLED.- Parameters:
cemtTerminal- anITerminalobject logged on to the CICS region and in an active CEMT session. If mixed case is required, the terminal should be presented with no upper case translate status.resourceType- aStringof the resource type you are looking for.resourceName- aStringof the name of the resource you are looking for.- Throws:
CemtException- - throws when error occurs in the CEMT transaction.
-