ServiceDescription serv = new ServiceDescription();
serv.getType().setName("FileBreedTest");
InputParameterType inputParameter = InputParameterType.Factory.newInstance();
inputParameter.setParameterName("Input_File");
inputParameter.setParameterDescription("File to Replicate");
ParameterType parameterType1 = inputParameter.addNewParameterType();
parameterType1.setType(DataType.Enum.forString("URI"));
inputParameter.setParameterType(URIParameterType.Factory.newInstance());
List<InputParameterType> inputList = new ArrayList<InputParameterType>();
inputList.add(inputParameter);
InputParameterType[] inputParamList = inputList.toArray(new InputParameterType[inputList
.size()]);
OutputParameterType outputParameter = OutputParameterType.Factory.newInstance();
ParameterType outputParameterType = outputParameter.addNewParameterType();
outputParameterType.setName("replicated_file");
outputParameterType.setType(DataType.URI);
List<OutputParameterType> outputList = new ArrayList<OutputParameterType>();
outputList.add(outputParameter);
OutputParameterType[] outputParamList = outputList
.toArray(new OutputParameterType[outputList.size()]);
serv.getType().setInputParametersArray(inputParamList);