X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.project%2Fsrc%2Forg%2Fsimantics%2Fproject%2Finternal%2FProjectFeatureExtension.java;fp=bundles%2Forg.simantics.project%2Fsrc%2Forg%2Fsimantics%2Fproject%2Finternal%2FProjectFeatureExtension.java;h=727ddbfb0e6fc655347ce87a93fe0cea72628288;hp=04eac0eaddac07ba2a98abe2ec6a142313daaa92;hb=0ae2b770234dfc3cbb18bd38f324125cf0faca07;hpb=24e2b34260f219f0d1644ca7a138894980e25b14 diff --git a/bundles/org.simantics.project/src/org/simantics/project/internal/ProjectFeatureExtension.java b/bundles/org.simantics.project/src/org/simantics/project/internal/ProjectFeatureExtension.java index 04eac0ead..727ddbfb0 100644 --- a/bundles/org.simantics.project/src/org/simantics/project/internal/ProjectFeatureExtension.java +++ b/bundles/org.simantics.project/src/org/simantics/project/internal/ProjectFeatureExtension.java @@ -1,99 +1,99 @@ -/******************************************************************************* - * Copyright (c) 2007, 2010 Association for Decentralized Information Management - * in Industry THTH ry. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * VTT Technical Research Centre of Finland - initial API and implementation - *******************************************************************************/ -package org.simantics.project.internal; - -import java.util.Collection; -import java.util.Collections; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.core.runtime.IConfigurationElement; -import org.simantics.project.features.IProjectFeature; -import org.simantics.project.features.registry.GroupReference; -import org.simantics.project.features.registry.IProjectFeatureExtension; -import org.simantics.project.features.registry.InjectedDependency; -import org.simantics.project.features.registry.ProjectFeatureReference; - -/** - * @author Tuukka Lehtonen - */ -class ProjectFeatureExtension implements IProjectFeatureExtension { - - // For access to createExecutableExtension(String). - private final IConfigurationElement configurationElement; - - private final String id; - private final String label; - private final String description; - private final boolean published; - - private final Collection requires; - private final Collection installGroups; - private final Collection injections; - - public ProjectFeatureExtension(IConfigurationElement ce, String id, String label, String description, - boolean published, Collection requires, Collection injections, - Collection installGroups) { - this.configurationElement = ce; - this.id = id; - this.label = label; - this.description = description; - this.published = published; - this.requires = Collections.unmodifiableCollection(requires); - this.injections = Collections.unmodifiableCollection(injections); - this.installGroups = Collections.unmodifiableCollection(installGroups); - } - - @Override - public String getId() { - return id; - } - - @Override - public String getLabel() { - return label; - } - - @Override - public String getDescription() { - return description; - } - - @Override - public boolean isPublished() { - return published; - } - - @Override - public Collection requires() { - return requires; - } - - public Collection injections() { - return injections; - } - - @Override - public Collection installGroups() { - return installGroups; - } - - @Override - public IProjectFeature newInstance() throws CoreException { - return (IProjectFeature) configurationElement.createExecutableExtension("class"); - } - - @Override - public String toString() { - return super.toString() + " [id=" + id + ", label=" + label + ", description=" + description + ", published=" + published + ", requires=" + requires + ", injections=" + injections + ", usedWithGroups=" + installGroups + "]"; - } - +/******************************************************************************* + * Copyright (c) 2007, 2010 Association for Decentralized Information Management + * in Industry THTH ry. + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * VTT Technical Research Centre of Finland - initial API and implementation + *******************************************************************************/ +package org.simantics.project.internal; + +import java.util.Collection; +import java.util.Collections; + +import org.eclipse.core.runtime.CoreException; +import org.eclipse.core.runtime.IConfigurationElement; +import org.simantics.project.features.IProjectFeature; +import org.simantics.project.features.registry.GroupReference; +import org.simantics.project.features.registry.IProjectFeatureExtension; +import org.simantics.project.features.registry.InjectedDependency; +import org.simantics.project.features.registry.ProjectFeatureReference; + +/** + * @author Tuukka Lehtonen + */ +class ProjectFeatureExtension implements IProjectFeatureExtension { + + // For access to createExecutableExtension(String). + private final IConfigurationElement configurationElement; + + private final String id; + private final String label; + private final String description; + private final boolean published; + + private final Collection requires; + private final Collection installGroups; + private final Collection injections; + + public ProjectFeatureExtension(IConfigurationElement ce, String id, String label, String description, + boolean published, Collection requires, Collection injections, + Collection installGroups) { + this.configurationElement = ce; + this.id = id; + this.label = label; + this.description = description; + this.published = published; + this.requires = Collections.unmodifiableCollection(requires); + this.injections = Collections.unmodifiableCollection(injections); + this.installGroups = Collections.unmodifiableCollection(installGroups); + } + + @Override + public String getId() { + return id; + } + + @Override + public String getLabel() { + return label; + } + + @Override + public String getDescription() { + return description; + } + + @Override + public boolean isPublished() { + return published; + } + + @Override + public Collection requires() { + return requires; + } + + public Collection injections() { + return injections; + } + + @Override + public Collection installGroups() { + return installGroups; + } + + @Override + public IProjectFeature newInstance() throws CoreException { + return (IProjectFeature) configurationElement.createExecutableExtension("class"); + } + + @Override + public String toString() { + return super.toString() + " [id=" + id + ", label=" + label + ", description=" + description + ", published=" + published + ", requires=" + requires + ", injections=" + injections + ", usedWithGroups=" + installGroups + "]"; + } + } \ No newline at end of file