You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2015/02/16 09:06:35 UTC
[10/59] [abbrv] [partial] syncope git commit: [SYNCOPE-620]
Re-organization completed
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/report/RoleReportletConf.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/report/RoleReportletConf.java b/common/src/main/java/org/apache/syncope/common/report/RoleReportletConf.java
deleted file mode 100644
index 4e4042d..0000000
--- a/common/src/main/java/org/apache/syncope/common/report/RoleReportletConf.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * 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.syncope.common.report;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.ArrayList;
-import java.util.List;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlRootElement;
-import javax.xml.bind.annotation.XmlType;
-
-import org.apache.syncope.common.annotation.FormAttributeField;
-import org.apache.syncope.common.types.IntMappingType;
-
-@XmlRootElement(name = "roleReportletConf")
-@XmlType
-public class RoleReportletConf extends AbstractReportletConf {
-
- private static final long serialVersionUID = -8488503068032439699L;
-
- @XmlEnum
- @XmlType(name = "roleReportletConfFeature")
- public enum Feature {
-
- id,
- name,
- roleOwner,
- userOwner,
- entitlements,
- users,
- resources
-
- }
-
- @FormAttributeField(userSearch = true)
- private String matchingCond;
-
- @FormAttributeField(schema = IntMappingType.RoleSchema)
- private final List<String> attrs = new ArrayList<String>();
-
- @FormAttributeField(schema = IntMappingType.RoleDerivedSchema)
- private final List<String> derAttrs = new ArrayList<String>();
-
- @FormAttributeField(schema = IntMappingType.RoleVirtualSchema)
- private final List<String> virAttrs = new ArrayList<String>();
-
- private final List<Feature> features = new ArrayList<Feature>();
-
- public RoleReportletConf() {
- super();
- }
-
- public RoleReportletConf(final String name) {
- super(name);
- }
-
- @XmlElementWrapper(name = "attributes")
- @XmlElement(name = "attribute")
- @JsonProperty("attributes")
- public List<String> getAttrs() {
- return attrs;
- }
-
- @XmlElementWrapper(name = "derivedAttributes")
- @XmlElement(name = "attribute")
- @JsonProperty("derivedAttributes")
- public List<String> getDerAttrs() {
- return derAttrs;
- }
-
- @XmlElementWrapper(name = "virtualAttributes")
- @XmlElement(name = "attribute")
- @JsonProperty("virtualAttributes")
- public List<String> getVirAttrs() {
- return virAttrs;
- }
-
- @XmlElementWrapper(name = "features")
- @XmlElement(name = "feature")
- @JsonProperty("features")
- public List<Feature> getFeatures() {
- return features;
- }
-
- public String getMatchingCond() {
- return matchingCond;
- }
-
- public void setMatchingCond(final String matchingCond) {
- this.matchingCond = matchingCond;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/report/StaticReportletConf.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/report/StaticReportletConf.java b/common/src/main/java/org/apache/syncope/common/report/StaticReportletConf.java
deleted file mode 100644
index 482b939..0000000
--- a/common/src/main/java/org/apache/syncope/common/report/StaticReportletConf.java
+++ /dev/null
@@ -1,109 +0,0 @@
-/*
- * 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.syncope.common.report;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlRootElement;
-import javax.xml.bind.annotation.XmlType;
-
-import org.apache.syncope.common.types.TraceLevel;
-
-@XmlRootElement(name = "staticReportletConf")
-@XmlType
-public class StaticReportletConf extends AbstractReportletConf {
-
- private static final long serialVersionUID = -4814950086361753689L;
-
- private String stringField;
-
- private Long longField;
-
- private Double doubleField;
-
- private Date dateField;
-
- private TraceLevel traceLevel;
-
- private final List<String> listField = new ArrayList<String>();
-
- public StaticReportletConf() {
- super();
- }
-
- public StaticReportletConf(final String name) {
- super(name);
- }
-
- public Date getDateField() {
- return dateField == null
- ? null
- : new Date(dateField.getTime());
- }
-
- public void setDateField(Date dateField) {
- this.dateField = dateField == null
- ? null
- : new Date(dateField.getTime());
- }
-
- public Double getDoubleField() {
- return doubleField;
- }
-
- public void setDoubleField(Double doubleField) {
- this.doubleField = doubleField;
- }
-
- @XmlElementWrapper(name = "listField")
- @XmlElement(name = "field")
- @JsonProperty("listField")
- public List<String> getListField() {
- return listField;
- }
-
- public Long getLongField() {
- return longField;
- }
-
- public void setLongField(Long longField) {
- this.longField = longField;
- }
-
- public String getStringField() {
- return stringField;
- }
-
- public void setStringField(String stringField) {
- this.stringField = stringField;
- }
-
- public TraceLevel getTraceLevel() {
- return traceLevel;
- }
-
- public void setTraceLevel(TraceLevel traceLevel) {
- this.traceLevel = traceLevel;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/report/UserReportletConf.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/report/UserReportletConf.java b/common/src/main/java/org/apache/syncope/common/report/UserReportletConf.java
deleted file mode 100644
index cd1cd3e..0000000
--- a/common/src/main/java/org/apache/syncope/common/report/UserReportletConf.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * 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.syncope.common.report;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlRootElement;
-import javax.xml.bind.annotation.XmlType;
-
-import org.apache.syncope.common.annotation.FormAttributeField;
-import org.apache.syncope.common.types.IntMappingType;
-
-@XmlRootElement(name = "userReportletConf")
-@XmlType
-public class UserReportletConf extends AbstractReportletConf {
-
- @XmlEnum
- @XmlType(name = "userReportletConfFeature")
- public enum Feature {
-
- id,
- username,
- workflowId,
- status,
- creationDate,
- lastLoginDate,
- changePwdDate,
- passwordHistorySize,
- failedLoginCount,
- memberships,
- resources
-
- }
-
- private static final long serialVersionUID = 6602717600064602764L;
-
- @FormAttributeField(userSearch = true)
- private String matchingCond;
-
- @FormAttributeField(schema = IntMappingType.UserSchema)
- private final List<String> attrs = new ArrayList<String>();
-
- @FormAttributeField(schema = IntMappingType.UserDerivedSchema)
- private final List<String> derAttrs = new ArrayList<String>();
-
- @FormAttributeField(schema = IntMappingType.UserVirtualSchema)
- private final List<String> virAttrs = new ArrayList<String>();
-
- private final List<Feature> features = new ArrayList<Feature>();
-
- public UserReportletConf() {
- super();
- }
-
- public UserReportletConf(final String name) {
- super(name);
- }
-
- @XmlElementWrapper(name = "attributes")
- @XmlElement(name = "attribute")
- @JsonProperty("attributes")
- public List<String> getAttrs() {
- return attrs;
- }
-
- @XmlElementWrapper(name = "derivedAttributes")
- @XmlElement(name = "attribute")
- @JsonProperty("derivedAttributes")
- public List<String> getDerAttrs() {
- return derAttrs;
- }
-
- @XmlElementWrapper(name = "virtualAttributes")
- @XmlElement(name = "attribute")
- @JsonProperty("virtualAttributes")
- public List<String> getVirAttrs() {
- return virAttrs;
- }
-
- @XmlElementWrapper(name = "features")
- @XmlElement(name = "feature")
- @JsonProperty("features")
- public List<Feature> getFeatures() {
- return features;
- }
-
- public String getMatchingCond() {
- return matchingCond;
- }
-
- public void setMatchingCond(final String matchingCond) {
- this.matchingCond = matchingCond;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/report/package-info.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/report/package-info.java b/common/src/main/java/org/apache/syncope/common/report/package-info.java
deleted file mode 100644
index 999bb08..0000000
--- a/common/src/main/java/org/apache/syncope/common/report/package-info.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * 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.
- */
-@XmlSchema(namespace = SyncopeConstants.NAMESPACE)
-package org.apache.syncope.common.report;
-
-import javax.xml.bind.annotation.XmlSchema;
-import org.apache.syncope.common.SyncopeConstants;
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/reqres/BulkAction.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/reqres/BulkAction.java b/common/src/main/java/org/apache/syncope/common/reqres/BulkAction.java
deleted file mode 100644
index 13fcf8f..0000000
--- a/common/src/main/java/org/apache/syncope/common/reqres/BulkAction.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * 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.syncope.common.reqres;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.ArrayList;
-import java.util.List;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlRootElement;
-import javax.xml.bind.annotation.XmlType;
-import org.apache.syncope.common.AbstractBaseBean;
-
-@XmlRootElement(name = "bulkAction")
-@XmlType
-public class BulkAction extends AbstractBaseBean {
-
- private static final long serialVersionUID = 1395353278878758961L;
-
- @XmlEnum
- @XmlType(name = "bulkActionType")
- public enum Type {
-
- DELETE,
- REACTIVATE,
- SUSPEND,
- DRYRUN,
- EXECUTE
-
- }
-
- private Type operation;
-
- /**
- * Serialized identifiers.
- */
- private final List<String> targets = new ArrayList<String>();
-
- public Type getOperation() {
- return operation;
- }
-
- public void setOperation(final Type operation) {
- this.operation = operation;
- }
-
- @XmlElementWrapper(name = "targets")
- @XmlElement(name = "target")
- @JsonProperty("targets")
- public List<String> getTargets() {
- return targets;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/reqres/BulkActionResult.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/reqres/BulkActionResult.java b/common/src/main/java/org/apache/syncope/common/reqres/BulkActionResult.java
deleted file mode 100644
index 9c46312..0000000
--- a/common/src/main/java/org/apache/syncope/common/reqres/BulkActionResult.java
+++ /dev/null
@@ -1,134 +0,0 @@
-/*
- * 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.syncope.common.reqres;
-
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlEnum;
-import javax.xml.bind.annotation.XmlRootElement;
-import javax.xml.bind.annotation.XmlType;
-import org.apache.syncope.common.AbstractBaseBean;
-
-@XmlRootElement(name = "bulkActionResult")
-@XmlType
-public class BulkActionResult extends AbstractBaseBean {
-
- private static final long serialVersionUID = 2868894178821778133L;
-
- @XmlEnum
- @XmlType(name = "bulkActionStatus")
- public enum Status {
-
- // general bulk action result statuses
- SUCCESS,
- FAILURE,
- // specific propagation task execution statuses
- CREATED,
- SUBMITTED,
- UNSUBMITTED;
-
- }
-
- private final List<Result> results = new ArrayList<Result>();
-
- @XmlElementWrapper(name = "result")
- @XmlElement(name = "item")
- @JsonProperty("result")
- public List<Result> getResult() {
- return results;
- }
-
- @JsonIgnore
- public void add(final Object id, final Status status) {
- if (id != null) {
- results.add(new Result(id.toString(), status));
- }
- }
-
- @JsonIgnore
- public void add(final Object id, final String status) {
- if (id != null) {
- results.add(new Result(id.toString(), Status.valueOf(status.toUpperCase())));
- }
- }
-
- @JsonIgnore
- public Map<String, Status> getResultMap() {
- final Map<String, Status> res = new HashMap<String, Status>();
-
- for (Result result : results) {
- res.put(result.getKey(), result.getValue());
- }
-
- return res;
- }
-
- @JsonIgnore
- public List<String> getResultByStatus(final Status status) {
- final List<String> res = new ArrayList<String>();
-
- for (Result result : results) {
- if (result.getValue() == status) {
- res.add(result.getKey());
- }
- }
-
- return res;
- }
-
- public static class Result extends AbstractBaseBean {
-
- private static final long serialVersionUID = -1149681964161193232L;
-
- private String key;
-
- private Status value;
-
- public Result() {
- super();
- }
-
- public Result(final String key, final Status value) {
- this.key = key;
- this.value = value;
- }
-
- public String getKey() {
- return key;
- }
-
- public Status getValue() {
- return value;
- }
-
- public void setKey(final String key) {
- this.key = key;
- }
-
- public void setValue(final Status value) {
- this.value = value;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/reqres/ErrorTO.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/reqres/ErrorTO.java b/common/src/main/java/org/apache/syncope/common/reqres/ErrorTO.java
deleted file mode 100644
index 166c986..0000000
--- a/common/src/main/java/org/apache/syncope/common/reqres/ErrorTO.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * 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.syncope.common.reqres;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.ArrayList;
-import java.util.List;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlRootElement;
-import javax.xml.bind.annotation.XmlType;
-import org.apache.syncope.common.AbstractBaseBean;
-import org.apache.syncope.common.types.ClientExceptionType;
-
-@XmlRootElement(name = "error")
-@XmlType
-public class ErrorTO extends AbstractBaseBean {
-
- private static final long serialVersionUID = 2435764161719225927L;
-
- private int status;
-
- private ClientExceptionType type;
-
- private final List<Object> elements = new ArrayList<Object>();
-
- public int getStatus() {
- return status;
- }
-
- public void setStatus(final int status) {
- this.status = status;
- }
-
- public ClientExceptionType getType() {
- return type;
- }
-
- public void setType(final ClientExceptionType type) {
- this.type = type;
- }
-
- @XmlElementWrapper(name = "elements")
- @XmlElement(name = "element")
- @JsonProperty("elements")
- public List<Object> getElements() {
- return elements;
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/reqres/PagedResult.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/reqres/PagedResult.java b/common/src/main/java/org/apache/syncope/common/reqres/PagedResult.java
deleted file mode 100644
index fd177cb..0000000
--- a/common/src/main/java/org/apache/syncope/common/reqres/PagedResult.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * 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.syncope.common.reqres;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import com.fasterxml.jackson.annotation.JsonTypeInfo;
-import java.net.URI;
-import java.util.ArrayList;
-import java.util.List;
-import javax.xml.bind.annotation.XmlElement;
-import javax.xml.bind.annotation.XmlElementWrapper;
-import javax.xml.bind.annotation.XmlRootElement;
-import javax.xml.bind.annotation.XmlType;
-import org.apache.syncope.common.AbstractBaseBean;
-
-@XmlRootElement(name = "pagedResult")
-@XmlType
-public class PagedResult<T extends AbstractBaseBean> extends AbstractBaseBean {
-
- private static final long serialVersionUID = 3472875885259250934L;
-
- private URI prev;
-
- private URI next;
-
- private final List<T> result = new ArrayList<T>();
-
- private int page;
-
- private int size;
-
- private int totalCount;
-
- public URI getPrev() {
- return prev;
- }
-
- public void setPrev(final URI prev) {
- this.prev = prev;
- }
-
- public URI getNext() {
- return next;
- }
-
- public void setNext(final URI next) {
- this.next = next;
- }
-
- @XmlElementWrapper(name = "result")
- @XmlElement(name = "item")
- @JsonProperty("result")
- @JsonTypeInfo(use = JsonTypeInfo.Id.CLASS, include = JsonTypeInfo.As.PROPERTY, property = "@class")
- public List<T> getResult() {
- return result;
- }
-
- public int getPage() {
- return page;
- }
-
- public void setPage(final int page) {
- this.page = page;
- }
-
- public int getSize() {
- return size;
- }
-
- public void setSize(final int size) {
- this.size = size;
- }
-
- public int getTotalCount() {
- return totalCount;
- }
-
- public void setTotalCount(final int totalCount) {
- this.totalCount = totalCount;
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/reqres/package-info.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/reqres/package-info.java b/common/src/main/java/org/apache/syncope/common/reqres/package-info.java
deleted file mode 100644
index 6f23599..0000000
--- a/common/src/main/java/org/apache/syncope/common/reqres/package-info.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * 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.
- */
-@XmlSchema(namespace = SyncopeConstants.NAMESPACE)
-package org.apache.syncope.common.reqres;
-
-import javax.xml.bind.annotation.XmlSchema;
-import org.apache.syncope.common.SyncopeConstants;
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/OrderByClauseBuilder.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/OrderByClauseBuilder.java b/common/src/main/java/org/apache/syncope/common/search/OrderByClauseBuilder.java
deleted file mode 100644
index 186fe2e..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/OrderByClauseBuilder.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import org.apache.commons.lang3.StringUtils;
-
-/**
- * Simple builder for generating <tt>orderby</tt> values.
- */
-public class OrderByClauseBuilder {
-
- private final StringBuilder builder = new StringBuilder();
-
- public OrderByClauseBuilder asc(final String key) {
- builder.append(key).append(" ASC,");
- return this;
- }
-
- public OrderByClauseBuilder desc(final String key) {
- builder.append(key).append(" DESC,");
- return this;
- }
-
- public String build() {
- return builder.length() == 0
- ? StringUtils.EMPTY
- : builder.deleteCharAt(builder.length() - 1).toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/RoleFiqlSearchConditionBuilder.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/RoleFiqlSearchConditionBuilder.java b/common/src/main/java/org/apache/syncope/common/search/RoleFiqlSearchConditionBuilder.java
deleted file mode 100644
index fb0e730..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/RoleFiqlSearchConditionBuilder.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import java.util.Map;
-import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
-import org.apache.cxf.jaxrs.ext.search.fiql.FiqlParser;
-
-/**
- * Extends <tt>SyncopeFiqlSearchConditionBuilder</tt> by providing some additional facilities for searching
- * roles in Syncope.
- */
-public class RoleFiqlSearchConditionBuilder extends SyncopeFiqlSearchConditionBuilder {
-
- public RoleFiqlSearchConditionBuilder() {
- super();
- }
-
- public RoleFiqlSearchConditionBuilder(final Map<String, String> properties) {
- super(properties);
- }
-
- @Override
- protected Builder newBuilderInstance() {
- return new Builder(properties);
- }
-
- @Override
- public RoleProperty is(final String property) {
- return newBuilderInstance().is(property);
- }
-
- public CompleteCondition hasEntitlements(final String entitlement, final String... moreEntitlements) {
- return newBuilderInstance().is(SpecialAttr.ENTITLEMENTS.toString()).
- hasEntitlements(entitlement, moreEntitlements);
- }
-
- public CompleteCondition hasNotEntitlements(final String entitlement, final String... moreEntitlements) {
- return newBuilderInstance().is(SpecialAttr.ENTITLEMENTS.toString()).
- hasNotEntitlements(entitlement, moreEntitlements);
- }
-
- protected static class Builder extends SyncopeFiqlSearchConditionBuilder.Builder
- implements RoleProperty, CompleteCondition {
-
- public Builder(final Map<String, String> properties) {
- super(properties);
- }
-
- public Builder(final Builder parent) {
- super(parent);
- }
-
- @Override
- public RoleProperty is(final String property) {
- Builder b = new Builder(this);
- b.result = property;
- return b;
- }
-
- @Override
- public CompleteCondition hasEntitlements(final String entitlement, final String... moreEntitlements) {
- this.result = SpecialAttr.ENTITLEMENTS.toString();
- return condition(FiqlParser.EQ, entitlement, (Object[]) moreEntitlements);
- }
-
- @Override
- public CompleteCondition hasNotEntitlements(final String entitlement, final String... moreEntitlements) {
- this.result = SpecialAttr.ENTITLEMENTS.toString();
- return condition(FiqlParser.NEQ, entitlement, (Object[]) moreEntitlements);
- }
-
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/RoleProperty.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/RoleProperty.java b/common/src/main/java/org/apache/syncope/common/search/RoleProperty.java
deleted file mode 100644
index 70938e1..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/RoleProperty.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
-
-public interface RoleProperty extends SyncopeProperty {
-
- CompleteCondition hasEntitlements(String entitlement, String... moreEntitlements);
-
- CompleteCondition hasNotEntitlements(String entitlement, String... moreEntitlements);
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/SearchableFields.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/SearchableFields.java b/common/src/main/java/org/apache/syncope/common/search/SearchableFields.java
deleted file mode 100644
index ce06934..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/SearchableFields.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import java.lang.reflect.Field;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import org.apache.commons.lang3.ArrayUtils;
-import org.apache.syncope.common.to.AbstractAttributableTO;
-import org.apache.syncope.common.to.RoleTO;
-import org.apache.syncope.common.to.UserTO;
-import org.apache.syncope.common.types.SubjectType;
-
-public class SearchableFields {
-
- protected static final String[] ATTRIBUTES_NOTINCLUDED = {
- "attrs", "derAttrs", "virAttrs",
- "serialVersionUID", "memberships", "entitlements", "resources", "password",
- "propagationTOs", "propagationStatusMap"
- };
-
- public static final List<String> get(final SubjectType subjectType) {
- return get(subjectType == SubjectType.USER
- ? UserTO.class
- : RoleTO.class);
- }
-
- public static final List<String> get(final Class<? extends AbstractAttributableTO> attributableRef) {
- final List<String> fieldNames = new ArrayList<String>();
-
- // loop on class and all superclasses searching for field
- Class<?> clazz = attributableRef;
- while (clazz != null && clazz != Object.class) {
- for (Field field : clazz.getDeclaredFields()) {
- if (!ArrayUtils.contains(ATTRIBUTES_NOTINCLUDED, field.getName())) {
- fieldNames.add(field.getName());
- }
- }
- clazz = clazz.getSuperclass();
- }
-
- Collections.reverse(fieldNames);
- return fieldNames;
-
- }
-
- private SearchableFields() {
- // empty constructor for static utility class
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/SpecialAttr.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/SpecialAttr.java b/common/src/main/java/org/apache/syncope/common/search/SpecialAttr.java
deleted file mode 100644
index 35572c6..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/SpecialAttr.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-public enum SpecialAttr {
-
- NULL("$null"),
- RESOURCES("$resources"),
- ROLES("$roles"),
- ENTITLEMENTS("$entitlements");
-
- private final String literal;
-
- SpecialAttr(final String literal) {
- this.literal = literal;
- }
-
- public static SpecialAttr fromString(final String value) {
- SpecialAttr result = null;
- for (SpecialAttr specialAttr : values()) {
- if (specialAttr.literal.equals(value)) {
- result = specialAttr;
- }
- }
-
- return result;
- }
-
- @Override
- public String toString() {
- return literal;
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/SyncopeFiqlSearchConditionBuilder.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/SyncopeFiqlSearchConditionBuilder.java b/common/src/main/java/org/apache/syncope/common/search/SyncopeFiqlSearchConditionBuilder.java
deleted file mode 100644
index 17bb608..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/SyncopeFiqlSearchConditionBuilder.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import java.util.HashMap;
-import java.util.Map;
-import org.apache.cxf.jaxrs.ext.search.SearchUtils;
-import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
-import org.apache.cxf.jaxrs.ext.search.client.FiqlSearchConditionBuilder;
-import org.apache.cxf.jaxrs.ext.search.fiql.FiqlParser;
-
-public abstract class SyncopeFiqlSearchConditionBuilder extends FiqlSearchConditionBuilder {
-
- public static final Map<String, String> CONTEXTUAL_PROPERTIES;
-
- static {
- CONTEXTUAL_PROPERTIES = new HashMap<String, String>();
- CONTEXTUAL_PROPERTIES.put(SearchUtils.LAX_PROPERTY_MATCH, "true");
- }
-
- protected SyncopeFiqlSearchConditionBuilder() {
- super();
- }
-
- protected SyncopeFiqlSearchConditionBuilder(final Map<String, String> properties) {
- super(properties);
- }
-
- @Override
- protected Builder newBuilderInstance() {
- return new Builder(properties);
- }
-
- public SyncopeProperty is(final String property) {
- return newBuilderInstance().is(property);
- }
-
- public CompleteCondition isNull(final String property) {
- return newBuilderInstance().is(property).nullValue();
- }
-
- public CompleteCondition isNotNull(final String property) {
- return newBuilderInstance().is(property).notNullValue();
- }
-
- public CompleteCondition hasResources(final String resource, final String... moreResources) {
- return newBuilderInstance().is(SpecialAttr.RESOURCES.toString()).hasResources(resource, moreResources);
- }
-
- public CompleteCondition hasNotResources(final String resource, final String... moreResources) {
- return newBuilderInstance().is(SpecialAttr.RESOURCES.toString()).hasNotResources(resource, moreResources);
- }
-
- protected static class Builder extends FiqlSearchConditionBuilder.Builder
- implements SyncopeProperty, CompleteCondition {
-
- protected Builder(final Map<String, String> properties) {
- super(properties);
- }
-
- protected Builder(final Builder parent) {
- super(parent);
- }
-
- @Override
- public SyncopeProperty is(final String property) {
- Builder b = new Builder(this);
- b.result = property;
- return b;
- }
-
- @Override
- public CompleteCondition nullValue() {
- return condition(FiqlParser.EQ, SpecialAttr.NULL);
- }
-
- @Override
- public CompleteCondition notNullValue() {
- return condition(FiqlParser.NEQ, SpecialAttr.NULL);
- }
-
- @Override
- public CompleteCondition hasResources(final String resource, final String... moreResources) {
- this.result = SpecialAttr.RESOURCES.toString();
- return condition(FiqlParser.EQ, resource, (Object[]) moreResources);
- }
-
- @Override
- public CompleteCondition hasNotResources(final String resource, final String... moreResources) {
- this.result = SpecialAttr.RESOURCES.toString();
- return condition(FiqlParser.NEQ, resource, (Object[]) moreResources);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/SyncopeProperty.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/SyncopeProperty.java b/common/src/main/java/org/apache/syncope/common/search/SyncopeProperty.java
deleted file mode 100644
index 782d31a..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/SyncopeProperty.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
-import org.apache.cxf.jaxrs.ext.search.client.Property;
-
-/**
- * Extension of fluent interface, for {@link SyncopeFiqlSearchConditionBuilder}.
- */
-public abstract interface SyncopeProperty extends Property {
-
- CompleteCondition nullValue();
-
- CompleteCondition notNullValue();
-
- CompleteCondition hasResources(String resource, String... moreResources);
-
- CompleteCondition hasNotResources(String resource, String... moreResources);
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/UserFiqlSearchConditionBuilder.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/UserFiqlSearchConditionBuilder.java b/common/src/main/java/org/apache/syncope/common/search/UserFiqlSearchConditionBuilder.java
deleted file mode 100644
index 6268544..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/UserFiqlSearchConditionBuilder.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import java.util.Map;
-import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
-import org.apache.cxf.jaxrs.ext.search.fiql.FiqlParser;
-
-/**
- * Extends <tt>SyncopeFiqlSearchConditionBuilder</tt> by providing some additional facilities for searching
- * users in Syncope.
- */
-public class UserFiqlSearchConditionBuilder extends SyncopeFiqlSearchConditionBuilder {
-
- public UserFiqlSearchConditionBuilder() {
- super();
- }
-
- public UserFiqlSearchConditionBuilder(final Map<String, String> properties) {
- super(properties);
- }
-
- @Override
- protected Builder newBuilderInstance() {
- return new Builder(properties);
- }
-
- @Override
- public UserProperty is(final String property) {
- return newBuilderInstance().is(property);
- }
-
- public CompleteCondition hasRoles(final Long role, final Long... moreRoles) {
- return newBuilderInstance().is(SpecialAttr.ROLES.toString()).hasRoles(role, moreRoles);
- }
-
- public CompleteCondition hasNotRoles(final Long role, final Long... moreRoles) {
- return newBuilderInstance().is(SpecialAttr.ROLES.toString()).hasNotRoles(role, moreRoles);
- }
-
- public CompleteCondition hasResources(final String resource, final String... moreResources) {
- return newBuilderInstance().is(SpecialAttr.RESOURCES.toString()).hasResources(resource, moreResources);
- }
-
- public CompleteCondition hasNotResources(final String resource, final String... moreResources) {
- return newBuilderInstance().is(SpecialAttr.RESOURCES.toString()).hasNotResources(resource, moreResources);
- }
-
- protected static class Builder extends SyncopeFiqlSearchConditionBuilder.Builder
- implements UserProperty, CompleteCondition {
-
- public Builder(final Map<String, String> properties) {
- super(properties);
- }
-
- public Builder(final Builder parent) {
- super(parent);
- }
-
- @Override
- public UserProperty is(final String property) {
- Builder b = new Builder(this);
- b.result = property;
- return b;
- }
-
- @Override
- public CompleteCondition hasRoles(final Long role, final Long... moreRoles) {
- this.result = SpecialAttr.ROLES.toString();
- return condition(FiqlParser.EQ, role, (Object[]) moreRoles);
- }
-
- @Override
- public CompleteCondition hasNotRoles(final Long role, final Long... moreRoles) {
- this.result = SpecialAttr.ROLES.toString();
- return condition(FiqlParser.NEQ, role, (Object[]) moreRoles);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/search/UserProperty.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/search/UserProperty.java b/common/src/main/java/org/apache/syncope/common/search/UserProperty.java
deleted file mode 100644
index ea8766e..0000000
--- a/common/src/main/java/org/apache/syncope/common/search/UserProperty.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * 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.syncope.common.search;
-
-import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
-
-public interface UserProperty extends SyncopeProperty {
-
- CompleteCondition hasRoles(Long role, Long... moreRoles);
-
- CompleteCondition hasNotRoles(Long role, Long... moreRoles);
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/services/ConfigurationService.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/services/ConfigurationService.java b/common/src/main/java/org/apache/syncope/common/services/ConfigurationService.java
deleted file mode 100644
index c678bb7..0000000
--- a/common/src/main/java/org/apache/syncope/common/services/ConfigurationService.java
+++ /dev/null
@@ -1,112 +0,0 @@
-/*
- * 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.syncope.common.services;
-
-import java.util.List;
-import javax.validation.constraints.NotNull;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.DELETE;
-import javax.ws.rs.GET;
-import javax.ws.rs.PUT;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
-import javax.ws.rs.core.Response;
-import org.apache.syncope.common.to.AttributeTO;
-import org.apache.syncope.common.to.ConfTO;
-import org.apache.syncope.common.wrap.MailTemplate;
-import org.apache.syncope.common.wrap.Validator;
-
-/**
- * REST operations for configuration.
- */
-@Path("configurations")
-public interface ConfigurationService extends JAXRSService {
-
- /**
- * Exports internal storage content as downloadable XML file.
- *
- * @return internal storage content as downloadable XML file
- */
- @GET
- @Path("stream")
- Response export();
-
- /**
- * Returns a list of known mail-template names.
- *
- * @return a list of known mail-template names
- */
- @GET
- @Path("mailTemplates")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<MailTemplate> getMailTemplates();
-
- /**
- * Returns a list of known validator names.
- *
- * @return a list of known validator names
- */
- @GET
- @Path("validators")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<Validator> getValidators();
-
- /**
- * Returns all configuration parameters.
- *
- * @return all configuration parameters
- */
- @GET
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- ConfTO list();
-
- /**
- * Returns configuration parameter with matching key.
- *
- * @param key identifier of configuration to be read
- * @return configuration parameter with matching key
- */
- @GET
- @Path("{key}")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- AttributeTO read(@NotNull @PathParam("key") String key);
-
- /**
- * Creates / updates the configuration parameter with the given key.
- *
- * @param key parameter key
- * @param value parameter value
- */
- @PUT
- @Path("{key}")
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- void set(@NotNull @PathParam("key") String key, @NotNull AttributeTO value);
-
- /**
- * Deletes the configuration parameter with matching key.
- *
- * @param key configuration parameter key
- */
- @DELETE
- @Path("{key}")
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- void delete(@NotNull @PathParam("key") String key);
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/services/ConnectorService.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/services/ConnectorService.java b/common/src/main/java/org/apache/syncope/common/services/ConnectorService.java
deleted file mode 100644
index 0e4ff92..0000000
--- a/common/src/main/java/org/apache/syncope/common/services/ConnectorService.java
+++ /dev/null
@@ -1,202 +0,0 @@
-/*
- * 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.syncope.common.services;
-
-import java.util.List;
-import javax.validation.constraints.NotNull;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.DELETE;
-import javax.ws.rs.DefaultValue;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
-import javax.ws.rs.QueryParam;
-import javax.ws.rs.core.MediaType;
-import javax.ws.rs.core.Response;
-import org.apache.cxf.jaxrs.model.wadl.Description;
-import org.apache.cxf.jaxrs.model.wadl.Descriptions;
-import org.apache.cxf.jaxrs.model.wadl.DocTarget;
-
-import org.apache.syncope.common.reqres.BulkAction;
-import org.apache.syncope.common.reqres.BulkActionResult;
-import org.apache.syncope.common.to.ConnBundleTO;
-import org.apache.syncope.common.to.ConnIdObjectClassTO;
-import org.apache.syncope.common.to.ConnInstanceTO;
-import org.apache.syncope.common.to.SchemaTO;
-import org.apache.syncope.common.types.ConnConfProperty;
-
-/**
- * REST operations for connector bundles and instances.
- */
-@Path("connectors")
-public interface ConnectorService extends JAXRSService {
-
- /**
- * Returns available connector bundles with property keys in selected language.
- *
- * @param lang language to select property keys; default language is English
- * @return available connector bundles with property keys in selected language
- */
- @GET
- @Path("bundles")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<ConnBundleTO> getBundles(@QueryParam("lang") String lang);
-
- /**
- * Returns configuration for given connector instance.
- *
- * @param connInstanceId connector instance id to read configuration from
- * @return configuration for given connector instance
- */
- @GET
- @Path("{connInstanceId}/configuration")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<ConnConfProperty> getConfigurationProperties(@NotNull @PathParam("connInstanceId") Long connInstanceId);
-
- /**
- * Returns schema names for connector bundle matching the given connector instance id.
- *
- * @param connInstanceId connector instance id to be used for schema lookup
- * @param connInstanceTO connector instance object to provide special configuration properties
- * @param includeSpecial if set to true, special schema names (like '__PASSWORD__') will be included;
- * default is false
- * @return schema names for connector bundle matching the given connector instance id
- */
- @POST
- @Path("{connInstanceId}/schemaNames")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<SchemaTO> getSchemaNames(@NotNull @PathParam("connInstanceId") Long connInstanceId,
- @NotNull ConnInstanceTO connInstanceTO,
- @QueryParam("includeSpecial") @DefaultValue("false") boolean includeSpecial);
-
- /**
- * Returns supported object classes for connector bundle matching the given connector instance id.
- *
- * @param connInstanceId connector instance id to be used for schema lookup
- * @param connInstanceTO connector instance object to provide special configuration properties
- * @return supported object classes for connector bundle matching the given connector instance id
- */
- @POST
- @Path("{connInstanceId}/supportedObjectClasses")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<ConnIdObjectClassTO> getSupportedObjectClasses(
- @NotNull @PathParam("connInstanceId") Long connInstanceId,
- @NotNull ConnInstanceTO connInstanceTO);
-
- /**
- * Returns connector instance with matching id.
- *
- * @param connInstanceId connector instance id to be read
- * @return connector instance with matching id
- */
- @GET
- @Path("{connInstanceId}")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- ConnInstanceTO read(@NotNull @PathParam("connInstanceId") Long connInstanceId);
-
- /**
- * Returns connector instance for matching resource.
- *
- * @param resourceName resource name to be used for connector lookup
- * @return connector instance for matching resource
- */
- @GET
- @Path("byResource/{resourceName}")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- ConnInstanceTO readByResource(@NotNull @PathParam("resourceName") String resourceName);
-
- /**
- * Returns a list of all connector instances with property keys in the matching language.
- *
- * @param lang language to select property keys, null for default (English).
- * An ISO 639 alpha-2 or alpha-3 language code, or a language subtag up to 8 characters in length.
- * @return list of all connector instances with property keys in the matching language
- */
- @GET
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<ConnInstanceTO> list(@QueryParam("lang") String lang);
-
- /**
- * Creates a new connector instance.
- *
- * @param connInstanceTO connector instance to be created
- * @return <tt>Response</tt> object featuring <tt>Location</tt> header of created connector instance
- */
- @Descriptions({
- @Description(target = DocTarget.RESPONSE,
- value = "Featuring <tt>Location</tt> header of created connector instance")
- })
- @POST
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- Response create(@NotNull ConnInstanceTO connInstanceTO);
-
- /**
- * Updates the connector instance matching the provided id.
- *
- * @param connInstanceId connector instance id to be updated
- * @param connInstanceTO connector instance to be stored
- */
- @PUT
- @Path("{connInstanceId}")
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- void update(@NotNull @PathParam("connInstanceId") Long connInstanceId, @NotNull ConnInstanceTO connInstanceTO);
-
- /**
- * Deletes the connector instance matching the provided id.
- *
- * @param connInstanceId connector instance id to be deleted
- */
- @DELETE
- @Path("{connInstanceId}")
- void delete(@NotNull @PathParam("connInstanceId") Long connInstanceId);
-
- /**
- * @param connInstanceTO connector instance to be used for connection check
- * @return true if connection could be established
- */
- @POST
- @Path("check")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- boolean check(@NotNull ConnInstanceTO connInstanceTO);
-
- /**
- * Reload all connector bundles and instances.
- */
- @POST
- @Path("reload")
- void reload();
-
- /**
- * Executes the provided bulk action.
- *
- * @param bulkAction list of connector instance ids against which the bulk action will be performed.
- * @return Bulk action result
- */
- @POST
- @Path("bulk")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- BulkActionResult bulk(@NotNull BulkAction bulkAction);
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/services/EntitlementService.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/services/EntitlementService.java b/common/src/main/java/org/apache/syncope/common/services/EntitlementService.java
deleted file mode 100644
index be2efea..0000000
--- a/common/src/main/java/org/apache/syncope/common/services/EntitlementService.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * 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.syncope.common.services;
-
-import java.util.List;
-
-import javax.ws.rs.GET;
-import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
-
-import org.apache.syncope.common.wrap.EntitlementTO;
-
-/**
- * REST operations for entitlements.
- */
-@Path("entitlements")
-public interface EntitlementService extends JAXRSService {
-
- /**
- * Returns a list of all known entitlements.
- *
- * @return list of all known entitlements
- */
- @GET
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<EntitlementTO> getAllEntitlements();
-
- /**
- * Returns a list of entitlements assigned to user making the current request.
- *
- * @return list of entitlements assigned to user making the current request
- */
- @GET
- @Path("own")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<EntitlementTO> getOwnEntitlements();
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/services/JAXRSService.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/services/JAXRSService.java b/common/src/main/java/org/apache/syncope/common/services/JAXRSService.java
deleted file mode 100644
index c801bb1..0000000
--- a/common/src/main/java/org/apache/syncope/common/services/JAXRSService.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * 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.syncope.common.services;
-
-public interface JAXRSService {
-
- final String PARAM_FIQL = "fiql";
-
- final String PARAM_PAGE = "page";
-
- final String DEFAULT_PARAM_PAGE = "1";
-
- final int DEFAULT_PARAM_PAGE_VALUE = Integer.valueOf(DEFAULT_PARAM_PAGE);
-
- final String PARAM_SIZE = "size";
-
- final String DEFAULT_PARAM_SIZE = "25";
-
- final int DEFAULT_PARAM_SIZE_VALUE = Integer.valueOf(DEFAULT_PARAM_SIZE);
-
- final String PARAM_ORDERBY = "orderby";
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/services/LoggerService.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/services/LoggerService.java b/common/src/main/java/org/apache/syncope/common/services/LoggerService.java
deleted file mode 100644
index 173c046..0000000
--- a/common/src/main/java/org/apache/syncope/common/services/LoggerService.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * 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.syncope.common.services;
-
-import java.util.List;
-import javax.validation.constraints.NotNull;
-
-import javax.ws.rs.Consumes;
-import javax.ws.rs.DELETE;
-import javax.ws.rs.GET;
-import javax.ws.rs.PUT;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
-
-import org.apache.syncope.common.to.EventCategoryTO;
-import org.apache.syncope.common.to.LoggerTO;
-import org.apache.syncope.common.types.LoggerType;
-
-/**
- * REST operations for logging and auditing.
- */
-@Path("logger")
-public interface LoggerService extends JAXRSService {
-
- /**
- * Returns a list of all managed events in audit.
- *
- * @return list of all managed events in audit
- */
- @GET
- @Path("events")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<EventCategoryTO> events();
-
- /**
- * Returns logger with matching type and name.
- *
- * @param type LoggerType to be selected.
- * @param name Logger name to be read
- * @return logger with matching type and name
- */
- @GET
- @Path("{type}/{name}")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- LoggerTO read(@NotNull @PathParam("type") LoggerType type, @NotNull @PathParam("name") final String name);
-
- /**
- * Returns a list of loggers with matching type.
- *
- * @param type LoggerType to be selected
- * @return list of loggers with matching type
- */
- @GET
- @Path("{type}")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<LoggerTO> list(@NotNull @PathParam("type") LoggerType type);
-
- /**
- * Creates or updates (if existing) the logger with matching name.
- *
- * @param type LoggerType to be selected
- * @param name Logger name to be updated
- * @param logger Logger to be created or updated
- */
- @PUT
- @Path("{type}/{name}")
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- void update(@NotNull @PathParam("type") LoggerType type, @NotNull @PathParam("name") String name,
- @NotNull LoggerTO logger);
-
- /**
- * Deletes the logger with matching name.
- *
- * @param type LoggerType to be selected
- * @param name Logger name to be deleted
- */
- @DELETE
- @Path("{type}/{name}")
- void delete(@NotNull @PathParam("type") LoggerType type, @NotNull @PathParam("name") String name);
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/services/NotificationService.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/services/NotificationService.java b/common/src/main/java/org/apache/syncope/common/services/NotificationService.java
deleted file mode 100644
index efba417..0000000
--- a/common/src/main/java/org/apache/syncope/common/services/NotificationService.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * 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.syncope.common.services;
-
-import java.util.List;
-import javax.validation.constraints.NotNull;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.DELETE;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
-import javax.ws.rs.core.Response;
-import org.apache.cxf.jaxrs.model.wadl.Description;
-import org.apache.cxf.jaxrs.model.wadl.Descriptions;
-import org.apache.cxf.jaxrs.model.wadl.DocTarget;
-
-import org.apache.syncope.common.to.NotificationTO;
-
-/**
- * REST operations for notifications.
- */
-@Path("notifications")
-public interface NotificationService extends JAXRSService {
-
- /**
- * Returns notification with matching id.
- *
- * @param notificationId id of notification to be read
- * @return notification with matching id
- */
- @GET
- @Path("{notificationId}")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- NotificationTO read(@NotNull @PathParam("notificationId") Long notificationId);
-
- /**
- * Returns a list of all notifications.
- *
- * @return list of all notifications.
- */
- @GET
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<NotificationTO> list();
-
- /**
- * Creates a new notification.
- *
- * @param notificationTO Creates a new notification.
- * @return <tt>Response</tt> object featuring <tt>Location</tt> header of created notification
- */
- @Descriptions({
- @Description(target = DocTarget.RESPONSE,
- value = "Featuring <tt>Location</tt> header of created notification")
- })
- @POST
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- Response create(@NotNull NotificationTO notificationTO);
-
- /**
- * Updates the notification matching the given id.
- *
- * @param notificationId id of notification to be updated
- * @param notificationTO notification to be stored
- */
- @PUT
- @Path("{notificationId}")
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- void update(@NotNull @PathParam("notificationId") Long notificationId, @NotNull NotificationTO notificationTO);
-
- /**
- * Deletes the notification matching the given id.
- *
- * @param notificationId id for notification to be deleted
- */
- @DELETE
- @Path("{notificationId}")
- void delete(@NotNull @PathParam("notificationId") Long notificationId);
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/2d194636/common/src/main/java/org/apache/syncope/common/services/PolicyService.java
----------------------------------------------------------------------
diff --git a/common/src/main/java/org/apache/syncope/common/services/PolicyService.java b/common/src/main/java/org/apache/syncope/common/services/PolicyService.java
deleted file mode 100644
index 99010d8..0000000
--- a/common/src/main/java/org/apache/syncope/common/services/PolicyService.java
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * 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.syncope.common.services;
-
-import java.util.List;
-import javax.validation.constraints.NotNull;
-import javax.ws.rs.Consumes;
-import javax.ws.rs.DELETE;
-import javax.ws.rs.GET;
-import javax.ws.rs.MatrixParam;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.MediaType;
-import javax.ws.rs.core.Response;
-import org.apache.cxf.jaxrs.model.wadl.Description;
-import org.apache.cxf.jaxrs.model.wadl.Descriptions;
-import org.apache.cxf.jaxrs.model.wadl.DocTarget;
-import org.apache.syncope.common.wrap.CorrelationRuleClass;
-import org.apache.syncope.common.to.AbstractPolicyTO;
-import org.apache.syncope.common.types.PolicyType;
-
-/**
- * REST operations for policies.
- */
-@Path("policies")
-public interface PolicyService extends JAXRSService {
-
- /**
- * Returns a list of classes to be used as correlation rules.
- *
- * @return list of classes to be used as correlation rules
- */
- @GET
- @Path("syncCorrelationRuleClasses")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- List<CorrelationRuleClass> getSyncCorrelationRuleClasses();
-
- /**
- * Returns the policy matching the given id.
- *
- * @param policyId id of requested policy
- * @param <T> response type (extending PolicyTO)
- * @return policy with matching id
- */
- @GET
- @Path("{policyId}")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- <T extends AbstractPolicyTO> T read(@NotNull @PathParam("policyId") Long policyId);
-
- /**
- * Returns the global policy for the given type.
- *
- * @param type PolicyType to read global policy from
- * @param <T> response type (extending PolicyTO)
- * @return global policy for matching type
- */
- @GET
- @Path("global")
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- <T extends AbstractPolicyTO> T readGlobal(@NotNull @MatrixParam("type") PolicyType type);
-
- /**
- * Returns a list of policies of the matching type.
- *
- * @param type Type selector for requested policies
- * @param <T> response type (extending PolicyTO)
- * @return list of policies with matching type
- */
- @GET
- @Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- <T extends AbstractPolicyTO> List<T> list(@NotNull @MatrixParam("type") PolicyType type);
-
- /**
- * Create a new policy.
- *
- * @param policyTO Policy to be created (needs to match type)
- * @param <T> response type (extending PolicyTO)
- * @return <tt>Response</tt> object featuring <tt>Location</tt> header of created policy
- */
- @Descriptions({
- @Description(target = DocTarget.RESPONSE, value = "Featuring <tt>Location</tt> header of created policy")
- })
- @POST
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- <T extends AbstractPolicyTO> Response create(@NotNull T policyTO);
-
- /**
- * Updates policy matching the given id.
- *
- * @param policyId id of policy to be updated
- * @param policyTO Policy to replace existing policy
- * @param <T> response type (extending PolicyTO)
- */
- @PUT
- @Path("{policyId}")
- @Consumes({ MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON })
- <T extends AbstractPolicyTO> void update(@NotNull @PathParam("policyId") Long policyId, @NotNull T policyTO);
-
- /**
- * Delete policy matching the given id.
- *
- * @param policyId id of policy to be deleted
- * @param <T> response type (extending PolicyTO)
- */
- @DELETE
- @Path("{policyId}")
- <T extends AbstractPolicyTO> void delete(@NotNull @PathParam("policyId") Long policyId);
-
-}