diff options
author | Pascal Rapicault | 2010-12-06 22:10:52 +0000 |
---|---|---|
committer | Pascal Rapicault | 2010-12-06 22:10:52 +0000 |
commit | fbb4f5902cade92cc1689e73209c60a6413a5ef7 (patch) | |
tree | ace0fb107bafe980fc14fd7f3429e5c9aac2d795 /org.eclipse.m2e.core/src/org/eclipse/m2e/core/project/ResolverConfiguration.java | |
parent | a9c878c2624b33d8c74062717bf75302f0ae1fa7 (diff) | |
download | m2e-core-fbb4f5902cade92cc1689e73209c60a6413a5ef7.tar.gz m2e-core-fbb4f5902cade92cc1689e73209c60a6413a5ef7.tar.xz m2e-core-fbb4f5902cade92cc1689e73209c60a6413a5ef7.zip |
Initial commit at Eclipse
Diffstat (limited to 'org.eclipse.m2e.core/src/org/eclipse/m2e/core/project/ResolverConfiguration.java')
-rw-r--r-- | org.eclipse.m2e.core/src/org/eclipse/m2e/core/project/ResolverConfiguration.java | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/org.eclipse.m2e.core/src/org/eclipse/m2e/core/project/ResolverConfiguration.java b/org.eclipse.m2e.core/src/org/eclipse/m2e/core/project/ResolverConfiguration.java new file mode 100644 index 00000000..8271bd19 --- /dev/null +++ b/org.eclipse.m2e.core/src/org/eclipse/m2e/core/project/ResolverConfiguration.java @@ -0,0 +1,56 @@ +/******************************************************************************* + * Copyright (c) 2008-2010 Sonatype, Inc. + * 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: + * Sonatype, Inc. - initial API and implementation + *******************************************************************************/ + +package org.eclipse.m2e.core.project; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +/** + * Resolver configuration holder. + * + * TODO need a better name, this configures all aspects of maven project in eclipse, + * not just dependency resolution. + * + * @author Eugene Kuleshov + */ +public class ResolverConfiguration implements Serializable { + private static final long serialVersionUID = 1258510761534886581L; + + private boolean resolveWorkspaceProjects = true; + + private String activeProfiles = ""; //$NON-NLS-1$ + + public boolean shouldResolveWorkspaceProjects() { + return this.resolveWorkspaceProjects; + } + + public String getActiveProfiles() { + return this.activeProfiles; + } + + public List<String> getActiveProfileList() { + if (activeProfiles.trim().length() > 0) { + return Arrays.asList(activeProfiles.split("[,\\s\\|]")); //$NON-NLS-1$ + } + return new ArrayList<String>(); + } + + public void setResolveWorkspaceProjects(boolean resolveWorkspaceProjects) { + this.resolveWorkspaceProjects = resolveWorkspaceProjects; + } + + public void setActiveProfiles(String activeProfiles) { + this.activeProfiles = activeProfiles; + } +} |