// Create and set the operation name
Operation operation = new OperationImpl();
operation.setName(name);
// Make the operation remotable
Interface iface = new InterfaceImpl();
iface.setRemotable(true);
operation.setInterface(iface);
// Construct the parameters
List<DataType> types = new ArrayList<DataType>();
DataType<List<DataType>> inputType = new DataTypeImpl<List<DataType>>(Object[].class, types);