Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  /*
   * Licensed to the Apache Software Foundation (ASF) under one
   * or more contributor license agreements.  See the NOTICE file
   * distributed with this work for additional information
   * regarding copyright ownership.  The ASF licenses this file
   * to you under the Apache License, Version 2.0 (the
   * "License"); you may not use this file except in compliance
   * with the License.  You may obtain a copy of the License at
   *
  *   http://www.apache.org/licenses/LICENSE-2.0
  *
  * Unless required by applicable law or agreed to in writing,
  * software distributed under the License is distributed on an
  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  * KIND, either express or implied.  See the License for the
  * specific language governing permissions and limitations
  * under the License.
  */
 
 package org.apache.tuscany.sca.node.configuration.impl;
 
 import java.io.Reader;
 import java.net.URI;
 import java.net.URL;
 import java.util.List;
 
Configuration for an SCA contribution used by the SCA node
 
     private String uri;
     private String location;
     private boolean startDeployables;
     private String metaDataURL;
 
     public ContributionConfigurationImpl() {
         super();
     }
 
     public ContributionConfigurationImpl(String uriString location) {
         super();
         this. = uri;
         this. = location;
     }
 
     public ContributionConfigurationImpl(String location) {
         super();
         this. = location;
         this. = location;
     }

    
Get the URI of the contribution

Returns:
The URI of the contribution
 
     public String getURI() {
         return ;
     }

    
Set the URI of the contribution

Parameters:
uri The URI of the contribution
 
     public ContributionConfiguration setURI(String uri) {
         this. = uri;
         return this;
     }

    
Get the location of the contribution

Returns:
The location of the contribution
 
     public String getLocation() {
         return ;
     }

    
Set the location of the contribution

Parameters:
location The location of the contribution
 
     public ContributionConfiguration setLocation(String location) {
         this. = location;
         return this;
     }

    
Get the list of deployment composites that are attached to the contribution

Returns:
 
        return ;
    }
        .add(deploymentComposite);
        if ( != null) {
            deploymentComposite.setContributionURI();
        }
        return this;
    }
        try {
            DeploymentComposite composite = new DeploymentCompositeImpl();
            char[] buf = new char[8192];
            StringWriter sw = new StringWriter();
            int size = 0;
            while (size >= 0) {
                size = reader.read(buf);
                if (size > 0) {
                    sw.write(buf, 0, size);
                }
            }
            reader.close();
            composite.setContent(sw.toString());
            return addDeploymentComposite(composite);
        } catch (IOException e) {
            throw new IllegalArgumentException(e);
        }
    }
        try {
            InputStreamReader reader = new InputStreamReader(content"UTF-8");
            return addDeploymentComposite(reader);
        } catch (IOException e) {
            throw new IllegalArgumentException(e);
        }
    }
        DeploymentComposite composite = new DeploymentCompositeImpl();
        composite.setContent(content);
        return addDeploymentComposite(composite);
    }
        DeploymentComposite composite = new DeploymentCompositeImpl();
        composite.setLocation(location.toString());
        return addDeploymentComposite(composite);
    }
        DeploymentComposite composite = new DeploymentCompositeImpl();
        composite.setLocation(location.toString());
        return addDeploymentComposite(composite);
    }
    @Override
    public void setStartDeployables(boolean startDeployables) {
        this. = startDeployables;
    }
    @Override
    public boolean isStartDeployables() {
        return ;
    }
    @Override
        return ;
    }
    @Override
    public void setDependentContributionURIs(List<StringdependentContributionURIs) {
        this. = dependentContributionURIs;
    }
    @Override
    public String getMetaDataURL() {
        return ;
    }
    @Override
    public void setMetaDataURL(String metaDataURL) {
        this. = metaDataURL;
    }
New to GrepCode? Check out our FAQ X