diff --git a/project-build.xml b/project-build.xml index c5819b09a1..430c6f7e7e 100644 --- a/project-build.xml +++ b/project-build.xml @@ -48,7 +48,7 @@ - + @@ -149,5 +149,19 @@ - + + + + + + + + + + + + + + + diff --git a/source/generated/org/alfresco/repo/webservice/administration/AdministrationFault.java b/source/generated/org/alfresco/repo/webservice/administration/AdministrationFault.java new file mode 100644 index 0000000000..3640e55db2 --- /dev/null +++ b/source/generated/org/alfresco/repo/webservice/administration/AdministrationFault.java @@ -0,0 +1,157 @@ +/** + * AdministrationFault.java + * + * This file was auto-generated from WSDL + * by the Apache Axis 1.2.1 Jun 14, 2005 (09:15:57 EDT) WSDL2Java emitter. + */ + +package org.alfresco.repo.webservice.administration; + +public class AdministrationFault extends org.apache.axis.AxisFault implements java.io.Serializable { + private int errorCode; + private java.lang.String message1; + + public AdministrationFault() { + } + + public AdministrationFault( + int errorCode, + java.lang.String message1) { + this.errorCode = errorCode; + this.message1 = message1; + } + + + /** + * Gets the errorCode value for this AdministrationFault. + * + * @return errorCode + */ + public int getErrorCode() { + return errorCode; + } + + + /** + * Sets the errorCode value for this AdministrationFault. + * + * @param errorCode + */ + public void setErrorCode(int errorCode) { + this.errorCode = errorCode; + } + + + /** + * Gets the message1 value for this AdministrationFault. + * + * @return message1 + */ + public java.lang.String getMessage1() { + return message1; + } + + + /** + * Sets the message1 value for this AdministrationFault. + * + * @param message1 + */ + public void setMessage1(java.lang.String message1) { + this.message1 = message1; + } + + private java.lang.Object __equalsCalc = null; + public synchronized boolean equals(java.lang.Object obj) { + if (!(obj instanceof AdministrationFault)) return false; + AdministrationFault other = (AdministrationFault) obj; + if (obj == null) return false; + if (this == obj) return true; + if (__equalsCalc != null) { + return (__equalsCalc == obj); + } + __equalsCalc = obj; + boolean _equals; + _equals = true && + this.errorCode == other.getErrorCode() && + ((this.message1==null && other.getMessage1()==null) || + (this.message1!=null && + this.message1.equals(other.getMessage1()))); + __equalsCalc = null; + return _equals; + } + + private boolean __hashCodeCalc = false; + public synchronized int hashCode() { + if (__hashCodeCalc) { + return 0; + } + __hashCodeCalc = true; + int _hashCode = 1; + _hashCode += getErrorCode(); + if (getMessage1() != null) { + _hashCode += getMessage1().hashCode(); + } + __hashCodeCalc = false; + return _hashCode; + } + + // Type metadata + private static org.apache.axis.description.TypeDesc typeDesc = + new org.apache.axis.description.TypeDesc(AdministrationFault.class, true); + + static { + typeDesc.setXmlType(new javax.xml.namespace.QName("http://www.alfresco.org/ws/service/administration/1.0", "AdministrationFault")); + org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc(); + elemField.setFieldName("errorCode"); + elemField.setXmlName(new javax.xml.namespace.QName("http://www.alfresco.org/ws/service/administration/1.0", "errorCode")); + elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "int")); + elemField.setNillable(false); + typeDesc.addFieldDesc(elemField); + elemField = new org.apache.axis.description.ElementDesc(); + elemField.setFieldName("message1"); + elemField.setXmlName(new javax.xml.namespace.QName("http://www.alfresco.org/ws/service/administration/1.0", "message")); + elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string")); + elemField.setNillable(false); + typeDesc.addFieldDesc(elemField); + } + + /** + * Return type metadata object + */ + public static org.apache.axis.description.TypeDesc getTypeDesc() { + return typeDesc; + } + + /** + * Get Custom Serializer + */ + public static org.apache.axis.encoding.Serializer getSerializer( + java.lang.String mechType, + java.lang.Class _javaType, + javax.xml.namespace.QName _xmlType) { + return + new org.apache.axis.encoding.ser.BeanSerializer( + _javaType, _xmlType, typeDesc); + } + + /** + * Get Custom Deserializer + */ + public static org.apache.axis.encoding.Deserializer getDeserializer( + java.lang.String mechType, + java.lang.Class _javaType, + javax.xml.namespace.QName _xmlType) { + return + new org.apache.axis.encoding.ser.BeanDeserializer( + _javaType, _xmlType, typeDesc); + } + + + /** + * Writes the exception data to the faultDetails + */ + public void writeDetails(javax.xml.namespace.QName qname, org.apache.axis.encoding.SerializationContext context) throws java.io.IOException { + context.serialize(qname, null, this); + } +} diff --git a/source/generated/org/alfresco/repo/webservice/administration/AdministrationServiceSoapPort.java b/source/generated/org/alfresco/repo/webservice/administration/AdministrationServiceSoapPort.java new file mode 100644 index 0000000000..11c9067dc4 --- /dev/null +++ b/source/generated/org/alfresco/repo/webservice/administration/AdministrationServiceSoapPort.java @@ -0,0 +1,46 @@ +/** + * AdministrationServiceSoapPort.java + * + * This file was auto-generated from WSDL + * by the Apache Axis 1.2.1 Jun 14, 2005 (09:15:57 EDT) WSDL2Java emitter. + */ + +package org.alfresco.repo.webservice.administration; + +public interface AdministrationServiceSoapPort extends java.rmi.Remote { + + /** + * Gets the details of the requested users. + */ + public org.alfresco.repo.webservice.administration.UserQueryResults queryUsers(org.alfresco.repo.webservice.administration.UserFilter filter) throws java.rmi.RemoteException, org.alfresco.repo.webservice.administration.AdministrationFault; + + /** + * Fetch the next bathc of users from an existing user query. + */ + public org.alfresco.repo.webservice.administration.UserQueryResults fetchMoreUsers(java.lang.String querySession) throws java.rmi.RemoteException, org.alfresco.repo.webservice.administration.AdministrationFault; + + /** + * Get the details of a specified user. + */ + public org.alfresco.repo.webservice.administration.UserDetails getUser(java.lang.String userName) throws java.rmi.RemoteException, org.alfresco.repo.webservice.administration.AdministrationFault; + + /** + * Create new users with the details provided. + */ + public org.alfresco.repo.webservice.administration.UserDetails[] createUsers(org.alfresco.repo.webservice.administration.NewUserDetails[] newUsers) throws java.rmi.RemoteException, org.alfresco.repo.webservice.administration.AdministrationFault; + + /** + * Updates the details of the specified users. + */ + public org.alfresco.repo.webservice.administration.UserDetails[] updateUsers(org.alfresco.repo.webservice.administration.UserDetails[] users) throws java.rmi.RemoteException, org.alfresco.repo.webservice.administration.AdministrationFault; + + /** + * Changes the password of the specified user. + */ + public void changePassword(java.lang.String userName, java.lang.String oldPassword, java.lang.String newPassword) throws java.rmi.RemoteException, org.alfresco.repo.webservice.administration.AdministrationFault; + + /** + * Delete the specified users. + */ + public void deleteUsers(java.lang.String[] userNames) throws java.rmi.RemoteException, org.alfresco.repo.webservice.administration.AdministrationFault; +} diff --git a/source/generated/org/alfresco/repo/webservice/administration/NewUserDetails.java b/source/generated/org/alfresco/repo/webservice/administration/NewUserDetails.java new file mode 100644 index 0000000000..b553299cc0 --- /dev/null +++ b/source/generated/org/alfresco/repo/webservice/administration/NewUserDetails.java @@ -0,0 +1,207 @@ +/** + * NewUserDetails.java + * + * This file was auto-generated from WSDL + * by the Apache Axis 1.2.1 Jun 14, 2005 (09:15:57 EDT) WSDL2Java emitter. + */ + +package org.alfresco.repo.webservice.administration; + +public class NewUserDetails implements java.io.Serializable { + private java.lang.String userName; + private java.lang.String password; + private org.alfresco.repo.webservice.types.NamedValue[] properties; + + public NewUserDetails() { + } + + public NewUserDetails( + java.lang.String userName, + java.lang.String password, + org.alfresco.repo.webservice.types.NamedValue[] properties) { + this.userName = userName; + this.password = password; + this.properties = properties; + } + + + /** + * Gets the userName value for this NewUserDetails. + * + * @return userName + */ + public java.lang.String getUserName() { + return userName; + } + + + /** + * Sets the userName value for this NewUserDetails. + * + * @param userName + */ + public void setUserName(java.lang.String userName) { + this.userName = userName; + } + + + /** + * Gets the password value for this NewUserDetails. + * + * @return password + */ + public java.lang.String getPassword() { + return password; + } + + + /** + * Sets the password value for this NewUserDetails. + * + * @param password + */ + public void setPassword(java.lang.String password) { + this.password = password; + } + + + /** + * Gets the properties value for this NewUserDetails. + * + * @return properties + */ + public org.alfresco.repo.webservice.types.NamedValue[] getProperties() { + return properties; + } + + + /** + * Sets the properties value for this NewUserDetails. + * + * @param properties + */ + public void setProperties(org.alfresco.repo.webservice.types.NamedValue[] properties) { + this.properties = properties; + } + + public org.alfresco.repo.webservice.types.NamedValue getProperties(int i) { + return this.properties[i]; + } + + public void setProperties(int i, org.alfresco.repo.webservice.types.NamedValue _value) { + this.properties[i] = _value; + } + + private java.lang.Object __equalsCalc = null; + public synchronized boolean equals(java.lang.Object obj) { + if (!(obj instanceof NewUserDetails)) return false; + NewUserDetails other = (NewUserDetails) obj; + if (obj == null) return false; + if (this == obj) return true; + if (__equalsCalc != null) { + return (__equalsCalc == obj); + } + __equalsCalc = obj; + boolean _equals; + _equals = true && + ((this.userName==null && other.getUserName()==null) || + (this.userName!=null && + this.userName.equals(other.getUserName()))) && + ((this.password==null && other.getPassword()==null) || + (this.password!=null && + this.password.equals(other.getPassword()))) && + ((this.properties==null && other.getProperties()==null) || + (this.properties!=null && + java.util.Arrays.equals(this.properties, other.getProperties()))); + __equalsCalc = null; + return _equals; + } + + private boolean __hashCodeCalc = false; + public synchronized int hashCode() { + if (__hashCodeCalc) { + return 0; + } + __hashCodeCalc = true; + int _hashCode = 1; + if (getUserName() != null) { + _hashCode += getUserName().hashCode(); + } + if (getPassword() != null) { + _hashCode += getPassword().hashCode(); + } + if (getProperties() != null) { + for (int i=0; + i + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/source/java/org/alfresco/repo/webservice/accesscontrol/AccessControlService.java b/source/java/org/alfresco/repo/webservice/accesscontrol/AccessControlWebService.java similarity index 95% rename from source/java/org/alfresco/repo/webservice/accesscontrol/AccessControlService.java rename to source/java/org/alfresco/repo/webservice/accesscontrol/AccessControlWebService.java index a105782b8d..c01b787960 100644 --- a/source/java/org/alfresco/repo/webservice/accesscontrol/AccessControlService.java +++ b/source/java/org/alfresco/repo/webservice/accesscontrol/AccessControlWebService.java @@ -6,7 +6,7 @@ import org.alfresco.repo.transaction.TransactionComponent; import org.alfresco.repo.webservice.AbstractWebService; import org.alfresco.repo.webservice.types.Predicate; -public class AccessControlService extends AbstractWebService implements AccessControlServiceSoapPort +public class AccessControlWebService extends AbstractWebService implements AccessControlServiceSoapPort { private TransactionComponent transactionService = null; diff --git a/source/java/org/alfresco/repo/webservice/administration/AdministrationWebService.java b/source/java/org/alfresco/repo/webservice/administration/AdministrationWebService.java new file mode 100644 index 0000000000..84b00f03c4 --- /dev/null +++ b/source/java/org/alfresco/repo/webservice/administration/AdministrationWebService.java @@ -0,0 +1,107 @@ +/* + * Copyright (C) 2005 Alfresco, Inc. + * + * Licensed under the Mozilla Public License version 1.1 + * with a permitted attribution clause. You may obtain a + * copy of the License at + * + * http://www.alfresco.org/legal/license.txt + * + * 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.alfresco.repo.webservice.administration; + +import java.rmi.RemoteException; + +import org.alfresco.repo.transaction.TransactionComponent; +import org.alfresco.repo.webservice.AbstractWebService; + +/** + * @author Roy Wetherall + */ +public class AdministrationWebService extends AbstractWebService implements + AdministrationServiceSoapPort +{ + private TransactionComponent transactionService = null; + + public void setTransactionService(TransactionComponent transactionService) + { + this.transactionService = transactionService; + } + + /* (non-Javadoc) + * @see org.alfresco.repo.webservice.administration.AdministrationServiceSoapPort#queryUsers(org.alfresco.repo.webservice.administration.UserFilter) + */ + public UserQueryResults queryUsers(UserFilter filter) + throws RemoteException, AdministrationFault + { + // TODO Auto-generated method stub + return null; + } + + /* (non-Javadoc) + * @see org.alfresco.repo.webservice.administration.AdministrationServiceSoapPort#fetchMoreUsers(java.lang.String) + */ + public UserQueryResults fetchMoreUsers(String querySession) + throws RemoteException, AdministrationFault + { + // TODO Auto-generated method stub + return null; + } + + /* (non-Javadoc) + * @see org.alfresco.repo.webservice.administration.AdministrationServiceSoapPort#getUser(java.lang.String) + */ + public UserDetails getUser(String userName) throws RemoteException, + AdministrationFault + { + // TODO Auto-generated method stub + return null; + } + + /* (non-Javadoc) + * @see org.alfresco.repo.webservice.administration.AdministrationServiceSoapPort#createUsers(org.alfresco.repo.webservice.administration.NewUserDetails[]) + */ + public UserDetails[] createUsers(NewUserDetails[] newUsers) + throws RemoteException, AdministrationFault + { + // TODO Auto-generated method stub + return null; + } + + /* (non-Javadoc) + * @see org.alfresco.repo.webservice.administration.AdministrationServiceSoapPort#updateUsers(org.alfresco.repo.webservice.administration.UserDetails[]) + */ + public UserDetails[] updateUsers(UserDetails[] users) + throws RemoteException, AdministrationFault + { + // TODO Auto-generated method stub + return null; + } + + /* (non-Javadoc) + * @see org.alfresco.repo.webservice.administration.AdministrationServiceSoapPort#changePassword(java.lang.String, java.lang.String, java.lang.String) + */ + public void changePassword(String userName, String oldPassword, + String newPassword) throws RemoteException, AdministrationFault + { + // TODO Auto-generated method stub + + } + + /* (non-Javadoc) + * @see org.alfresco.repo.webservice.administration.AdministrationServiceSoapPort#deleteUsers(java.lang.String[]) + */ + public void deleteUsers(String[] userNames) throws RemoteException, + AdministrationFault + { + // TODO Auto-generated method stub + + } + +} diff --git a/source/java/web-services-application-context.xml b/source/java/web-services-application-context.xml index 8e83bf1f21..f102ae4da7 100644 --- a/source/java/web-services-application-context.xml +++ b/source/java/web-services-application-context.xml @@ -162,7 +162,22 @@ - + + + + + + + + + + + + + + + + diff --git a/source/web/WEB-INF/server-config.wsdd b/source/web/WEB-INF/server-config.wsdd index 237d0cb997..1dc1a4ddc7 100644 --- a/source/web/WEB-INF/server-config.wsdd +++ b/source/web/WEB-INF/server-config.wsdd @@ -2696,6 +2696,344 @@ encodingStyle="" /> + + + Administration web service API. + /wsdl/administration-service.wsdl + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/source/wsdl/administration-service.wsdl b/source/wsdl/administration-service.wsdl new file mode 100644 index 0000000000..2e97db4db1 --- /dev/null +++ b/source/wsdl/administration-service.wsdl @@ -0,0 +1,399 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Gets the details of the requested users. + + + + + + + + + Fetch the next bathc of users from an existing user query. + + + + + + + + + Get the details of a specified user. + + + + + + + + + Create new users with the details provided. + + + + + + + + + Updates the details of the specified users. + + + + + + + + + Changes the password of the specified user. + + + + + + + + + Delete the specified users. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Administration service. + + + + + + \ No newline at end of file