public Object getAdapter()

in plugins/org.apache.karaf.eik.core/src/main/java/org/apache/karaf/eik/core/model/GenericKarafPlatformModel.java [73:96]


    public Object getAdapter(@SuppressWarnings("rawtypes") final Class adapterType) {
        final Object adaptedObject;
        if (adapterType == FeaturesSection.class) {
            adaptedObject = new FeaturesSectionImpl(this);
        } else if (adapterType == ShellSection.class) {
            adaptedObject = new ShellSectionImpl(this);
        }else if (adapterType == GeneralSection.class) {
            adaptedObject = new GeneralSectionImpl(this);
        } else if (adapterType == ManagementSection.class) {
            adaptedObject = adaptManagementSection();
        } else if (adapterType == StartupSection.class) {
            adaptedObject = new StartupSectionImpl(this);
        } else if (adapterType == SystemSection.class) {
            return new SystemSectionImpl(this);
        } else if (adapterType == KarafPlatformDetails.class) {
            adaptedObject = adaptKarafPlatformDetails();
        } else if (adapterType == KarafSshConnectionUrl.class) {
            adaptedObject = adaptKarafSshConnectionUrl();
        } else {
            adaptedObject = Platform.getAdapterManager().getAdapter(this, adapterType);
        }

        return adaptedObject;
    }