Class NotificationFunctions
java.lang.Object
flexagon.fd.model2.notification.functions.NotificationFunctions
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionformatDateTime(Timestamp pTimestamp) Returns date in format dd MMM, yyyy HH:mm a zReturns list of all active build environmentsReturns list of all active environmentsReturns list of all environments in topologyReturns list of all build environmentsgetDescriptionForInputField(InputField pInputField) This method is used to generate the Approval reply links for an event to attach to the event templategetEnvironmentByCode(String pEnvironmentCode) Returns environment object for environment with supplied code, or null if environment is not foundgetEnvironmentById(Long pEnvironmentId) Returns environment object for environment with supplied id, or null if environment is not foundReturns base FlexDeploy URL as configured in system settingsReturns the FlexDeploy Server host name.getFullDeployProjectEnvironmentState(NotifProjectVersion pProjectVersion, Long pProjectId, Long pEnvironmentId, NotifPipelineStageExecInfo pNotifPipelineStageExecInfo) Gets the current project state for a particular full deploy project version and environmentgetInstanceByCode(String pInstanceCode) Returns instance object for instance with supplied code, or null if instance is not foundgetInstanceById(Long pInstanceId) Returns instance object for instance with supplied id, or null if instance is not foundgetPartialDeployProjectEnvironmentState(NotifProjectVersion pProjectVersion, Long pProjectId, Long pEnvironmentId, NotifPipelineStageExecInfo pNotifPipelineStageExecInfo) Gets the current project state for a particular partial deploy project version and environmentbooleanReturns true if the Attach Logs system setting is set to AlwaysbooleanReturns true if the Attach Logs system setting is set to NeverbooleanReturns true if the Attach Logs system setting is set to On FailuretoPascalCase(String pInputString)
-
Constructor Details
-
NotificationFunctions
public NotificationFunctions()
-
-
Method Details
-
toPascalCase
- Parameters:
pInputString-- Returns:
-
getEmailApprovalByReplySection
This method is used to generate the Approval reply links for an event to attach to the event template- Parameters:
pPayload- Notification payload- Returns:
- HTML for email approval links section
-
getEmailApprovalByReplySectionForManualStep
public String getEmailApprovalByReplySectionForManualStep(NotificationPayload pPayload) throws SQLException - Throws:
SQLException
-
getDescriptionForInputField
-
getPartialDeployProjectEnvironmentState
public List<NotifProjectState> getPartialDeployProjectEnvironmentState(NotifProjectVersion pProjectVersion, Long pProjectId, Long pEnvironmentId, NotifPipelineStageExecInfo pNotifPipelineStageExecInfo) throws SQLException Gets the current project state for a particular partial deploy project version and environment- Throws:
SQLException
-
getFullDeployProjectEnvironmentState
public List<NotifProjectState> getFullDeployProjectEnvironmentState(NotifProjectVersion pProjectVersion, Long pProjectId, Long pEnvironmentId, NotifPipelineStageExecInfo pNotifPipelineStageExecInfo) throws SQLException Gets the current project state for a particular full deploy project version and environment- Throws:
SQLException
-
formatDateTime
Returns date in format dd MMM, yyyy HH:mm a z -
getFlexDeployBaseUrl
Returns base FlexDeploy URL as configured in system settings -
getFlexDeployHostname
Returns the FlexDeploy Server host name. This relies on the Server base url being configured in System Settings.- Returns:
- The hostname of the current FlexDeploy service.
- Since:
- 9.0.0.3
-
getAllEnvironments
Returns list of all environments in topology -
getEnvironmentById
Returns environment object for environment with supplied id, or null if environment is not found -
getEnvironmentByCode
Returns environment object for environment with supplied code, or null if environment is not found -
getBuildEnvironments
Returns list of all build environments -
getActiveEnvironments
Returns list of all active environments -
getActiveBuildEnvironments
Returns list of all active build environments -
getInstanceById
Returns instance object for instance with supplied id, or null if instance is not found -
getInstanceByCode
Returns instance object for instance with supplied code, or null if instance is not found -
isAttachLogsAlways
public boolean isAttachLogsAlways()Returns true if the Attach Logs system setting is set to Always -
isAttachLogsOnFailure
public boolean isAttachLogsOnFailure()Returns true if the Attach Logs system setting is set to On Failure -
isAttachLogsNever
public boolean isAttachLogsNever()Returns true if the Attach Logs system setting is set to Never
-