Search in sources :

Example 1 with ContextException

use of org.codehaus.plexus.context.ContextException in project intellij-community by JetBrains.

the class Maven3ServerEmbedderImpl method getProfileActivators.

private static ProfileActivator[] getProfileActivators(File basedir) throws RemoteException {
    SystemPropertyProfileActivator sysPropertyActivator = new SystemPropertyProfileActivator();
    DefaultContext context = new DefaultContext();
    context.put("SystemProperties", MavenServerUtil.collectSystemProperties());
    try {
        sysPropertyActivator.contextualize(context);
    } catch (ContextException e) {
        Maven3ServerGlobals.getLogger().error(e);
        return new ProfileActivator[0];
    }
    return new ProfileActivator[] { new MyFileProfileActivator(basedir), sysPropertyActivator, new JdkPrefixProfileActivator(), new OperatingSystemProfileActivator() };
}
Also used : DefaultContext(org.codehaus.plexus.context.DefaultContext) ContextException(org.codehaus.plexus.context.ContextException)

Example 2 with ContextException

use of org.codehaus.plexus.context.ContextException in project intellij-community by JetBrains.

the class Maven2ServerEmbedderImpl method getProfileActivators.

private static ProfileActivator[] getProfileActivators(File basedir) throws RemoteException {
    SystemPropertyProfileActivator sysPropertyActivator = new SystemPropertyProfileActivator();
    DefaultContext context = new DefaultContext();
    context.put("SystemProperties", MavenServerUtil.collectSystemProperties());
    try {
        sysPropertyActivator.contextualize(context);
    } catch (ContextException e) {
        Maven2ServerGlobals.getLogger().error(e);
        return new ProfileActivator[0];
    }
    return new ProfileActivator[] { new MyFileProfileActivator(basedir), sysPropertyActivator, new JdkPrefixProfileActivator(), new OperatingSystemProfileActivator() };
}
Also used : DefaultContext(org.codehaus.plexus.context.DefaultContext) ContextException(org.codehaus.plexus.context.ContextException)

Example 3 with ContextException

use of org.codehaus.plexus.context.ContextException in project intellij-community by JetBrains.

the class Maven30ServerEmbedderImpl method getProfileActivators.

private static ProfileActivator[] getProfileActivators(File basedir) throws RemoteException {
    SystemPropertyProfileActivator sysPropertyActivator = new SystemPropertyProfileActivator();
    DefaultContext context = new DefaultContext();
    context.put("SystemProperties", MavenServerUtil.collectSystemProperties());
    try {
        sysPropertyActivator.contextualize(context);
    } catch (ContextException e) {
        Maven3ServerGlobals.getLogger().error(e);
        return new ProfileActivator[0];
    }
    return new ProfileActivator[] { new MyFileProfileActivator(basedir), sysPropertyActivator, new JdkPrefixProfileActivator(), new OperatingSystemProfileActivator() };
}
Also used : DefaultContext(org.codehaus.plexus.context.DefaultContext) ContextException(org.codehaus.plexus.context.ContextException)

Aggregations

ContextException (org.codehaus.plexus.context.ContextException)3 DefaultContext (org.codehaus.plexus.context.DefaultContext)3