Class DTGatewayInterface

  • All Implemented Interfaces:
    GatewayConstants

    public class DTGatewayInterface
    extends java.lang.Object
    implements GatewayConstants
    This is the designer interface to the gateway, which defines various designer-only function to deal with the gateway
    • Constructor Detail

      • DTGatewayInterface

        protected DTGatewayInterface()
    • Method Detail

      • getAuthProfiles

        public java.util.Map<java.lang.String,​java.lang.Long> getAuthProfiles​(java.awt.Component owner)
                                                                             throws GatewayException
        Throws:
        GatewayException
      • getTableList

        @Deprecated(since="8.1.27")
        public java.lang.String[] getTableList​(java.awt.Component owner,
                                               java.lang.String datasource)
                                        throws GatewayException
        Deprecated.
        Prefer calling getTableList(String) in a SwingWorker for true async.
        Fetches the list of tables in datasource
        Parameters:
        owner - The component invoking this action; used as the basis for the automatic UI that will be displayed if this task takes longer than 3 seconds.
        Returns:
        A sorted array of table names in the specified datasource.
        Throws:
        GatewayException - If there's any issue communicating with the gateway
      • getTableList

        public java.lang.String[] getTableList​(java.lang.String datasource)
                                        throws GatewayException
        Fetches the list of tables in datasource
        Returns:
        A sorted array of table names in the specified datasource.
        Throws:
        GatewayException - If there's any issue communicating with the gateway
      • getColumnList

        @Deprecated(since="8.1.27")
        public Dataset getColumnList​(java.awt.Component owner,
                                     java.lang.String datasource,
                                     java.lang.String tablename)
                              throws GatewayException
        Deprecated.
        Silently blocks the EDT with a modal dialog. Prefer calling getColumnList(String, String) from a SwingWorker.
        Returns a dataset where each row represents a column in the table. The rows are:
        • column_name (name of column)
        • data_type (type code from java.sql.Types)
        • type_name (database dependent name of type)
        • column_size (precision/length)
        • primary_key (boolean indicating key status)
        • indexed (boolean indicating index status)
        Throws:
        GatewayException
      • getColumnList

        public Dataset getColumnList​(java.lang.String datasource,
                                     java.lang.String tablename)
                              throws GatewayException
        Returns a dataset where each row represents a column in the table. The rows are:
        • column_name (name of column)
        • data_type (type code from java.sql.Types)
        • type_name (database dependent name of type)
        • column_size (precision/length)
        • primary_key (boolean indicating key status)
        • indexed (boolean indicating index status)
        Throws:
        GatewayException
      • createImageFolder

        public void createImageFolder​(java.awt.Component dlg,
                                      java.lang.String name,
                                      java.lang.String parent)
                               throws GatewayException
        Throws:
        GatewayException
      • copyImage

        public void copyImage​(java.awt.Component dlg,
                              java.lang.String dest,
                              java.lang.String[] paths)
                       throws GatewayException
        Throws:
        GatewayException
      • renameImageFolder

        public void renameImageFolder​(java.awt.Component dlg,
                                      java.lang.String from,
                                      java.lang.String dest)
                               throws GatewayException
        Throws:
        GatewayException
      • uploadImage

        public void uploadImage​(java.awt.Component dlg,
                                java.lang.String name,
                                java.lang.String desc,
                                java.lang.String type,
                                java.lang.String parentDir,
                                int width,
                                int height,
                                byte[] data)
                         throws GatewayException
        Throws:
        GatewayException
      • loadProject

        public RuntimeProject loadProject​(java.lang.String projectName)
                                   throws java.lang.Exception
        Note - loads synchronously
        Parameters:
        projectName - the project name
        Throws:
        java.lang.Exception - on failure to load project
      • getExistingGlobalProps

        @Nullable
        public GlobalProps getExistingGlobalProps​(java.lang.String projectName)
                                           throws java.lang.Exception
        Throws:
        java.lang.Exception