Class ACMSDKHelpers


  • public class ACMSDKHelpers
    extends java.lang.Object
    ACMSDKHelpers has miscellaneous semi-generic helper methods
    • Constructor Detail

      • ACMSDKHelpers

        public ACMSDKHelpers()
    • Method Detail

      • invalidateRefreshClusterMembership

        public static void invalidateRefreshClusterMembership()
      • refreshAllClusterInfo

        public static void refreshAllClusterInfo()
      • close

        public static void close​(IDSSXMLSessionId iSessionId,
                                 ACMMasterSessionBundle iMasterSessionBundle,
                                 ACMClusterInfo iClusterInfo)
        close will close the Session to the IServer. If the session is a Project Session Id or a Configuration Session Id, then just that session id is closed. If the session is a Master Session Id, then all Project and Configuration sessions under it will also be closed.
        Parameters:
        iSessionId - a Project, Configuration, or Master session id
        iMasterSessionBundle - holds GSS credentials, needed to communicate with the kerberos server
        iClusterInfo - holds connectivity information to the session id
      • closeJustThisOne

        public static void closeJustThisOne​(IDSSXMLSessionId iSessionId,
                                            ACMMasterSessionBundle iMasterSessionBundle,
                                            java.util.Optional<ACMClusterInfo> iClusterInfoOpt)
        closeJustThisOne will close exactly the session. If it's a project session, then only that project portion will be closed. If it's a config session, then close the whole session.
        Parameters:
        iSessionId -
        iMasterSessionBundle -
        iClusterInfo -
      • getAllPidsInCluster

        public static java.util.Map<java.lang.String,​java.lang.String> getAllPidsInCluster​(IDSSXMLServerSession iServerSession)
                                                                                          throws MSTRWebAPIException
        getAllPidsInCluster returns a map of all the project ids in the cluster that the input iServerSession belongs to. The key is on Project ID, the value is on Project Name The operation is O(N) where N is the number of projects in the cluster
        Parameters:
        iServerSession - the session id to use to communicate with the IServer
        Returns:
        a hashmap containing all the project ids in the cluster.
        Throws:
        MSTRWebAPIException
      • portCompare

        public static boolean portCompare​(int iPort1,
                                          int iPort2)
      • portCompareTo

        public static int portCompareTo​(int iPort1,
                                        int iPort2)
      • portSpecified

        public static boolean portSpecified​(int iPort1,
                                            int iPort2)
        portSpecified returns true if all ports are specified. An unspecified port (a port with a negative value) indicates that the ports should not be used to compare with each other
        Parameters:
        iPort1 -
        iPort2 -
        Returns:
      • portResolve

        public static int portResolve​(int iPort)
        portResolve uses the port as is, unless the port is 0. When the port is 0 it converts it into the default port (34952)
        Parameters:
        iPort -
        Returns: