Package com.volantis.mcs.repository.jdbc

Examples of com.volantis.mcs.repository.jdbc.JDBCRepositoryConnection


    public RepositoryEnumeration enumerateCategoryNames(
                final RepositoryConnection connection)
            throws RepositoryException {

        // Cast the repository connection to a JDBC Connection.
        final JDBCRepositoryConnection jdbcConnection
               = (JDBCRepositoryConnection) connection;

        // Resolve field name.
        final String projectField =
            resolveFieldName(jdbcConnection, PROJECT_COLUMN_NAMES);
        final String categoryNameField =
            resolveFieldName(jdbcConnection, CATEGORY_NAME_COLUMN_NAMES);
        final String languageField =
            resolveFieldName(jdbcConnection, LANGUAGE_COLUMN_NAMES);

        // Resolve table name.
        final String vmPolicyCategoryTable =
            resolveTableName(jdbcConnection, VMPOLICY_CATEGORY);

        // Get the java.sql.Connection out of the JDBC Connection.
        final Connection sqlConnection = jdbcConnection.getConnection();

        Statement stmt = null;
        try {
            stmt = sqlConnection.createStatement();
View Full Code Here


            String policyName,
            PolicyDescriptor descriptor)
            throws RepositoryException {

        // Cast the repository connection to a JDBC Connection.
        JDBCRepositoryConnection jdbcConnection
                = (JDBCRepositoryConnection) connection;

        // First, see if we have a Category we can use.
        String categoryName = descriptor.getCategoryName();
        Integer categoryId = selectPolicyCategoryId(jdbcConnection,
View Full Code Here

            String categoryName,
            CategoryDescriptor descriptor)
            throws RepositoryException {

        // Cast the repository connection to a JDBC Connection.
        JDBCRepositoryConnection jdbcConnection
                = (JDBCRepositoryConnection) connection;

        Integer categoryId =
            selectPolicyCategoryId(jdbcConnection, categoryName);
        if (categoryId == null) {
View Full Code Here

            RepositoryConnection connection,
            String policyName)
            throws RepositoryException {

        // Cast the repository connection to a JDBC Connection.
        JDBCRepositoryConnection jdbcConnection
                = (JDBCRepositoryConnection) connection;

        // Select the type instance id and category from VMPOLICY_TYPE.
        PolicyTypeData policyType = selectPolicyType(jdbcConnection,
                policyName);
View Full Code Here

    }

    public void removeAllPolicyDescriptors(RepositoryConnection connection)
            throws RepositoryException {
        // Cast the repository connection to a JDBC Connection.
        JDBCRepositoryConnection jdbcConnection
                = (JDBCRepositoryConnection) connection;

        removeAllByTableName(jdbcConnection, VMTYPES_SET);
        removeAllByTableName(jdbcConnection, VMTYPES_STRUCTURE);
        removeAllByTableName(jdbcConnection, VMTYPES_RANGE);
View Full Code Here

    public void removeCategoryDescriptor(final RepositoryConnection connection,
                                         final String categoryName)
        throws RepositoryException {

        // Cast the repository connection to a JDBC Connection.
        final JDBCRepositoryConnection jdbcConnection =
            (JDBCRepositoryConnection) connection;

        final Integer categoryID =
            selectPolicyCategoryId(jdbcConnection, categoryName);
        if (categoryID != null) {
View Full Code Here

    }

    public void removeAllCategoryDescriptors(RepositoryConnection connection)
            throws RepositoryException {
        // Cast the repository connection to a JDBC Connection.
        final JDBCRepositoryConnection jdbcConnection =
            (JDBCRepositoryConnection) connection;

        removeAllByTableName(jdbcConnection, VMPOLICY_CATEGORY);
    }
View Full Code Here

TOP

Related Classes of com.volantis.mcs.repository.jdbc.JDBCRepositoryConnection

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.