diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 920b26d9..9f59d4c3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ env: ORG_GRADLE_PROJECT_sonatype_password: ${{ secrets.SONATYPE_S01_PASSWORD }} BRANCH_NAME: ${{ github.ref_name }} jobs: - apix-interface: + alfred-api-interface: runs-on: ubuntu-latest steps: - name: Check out @@ -30,18 +30,18 @@ jobs: - name: Build interface # Execute before integration testing to catch errors early uses: gradle/gradle-build-action@v2.3.0 with: - arguments: :apix-interface:build :apix-interface:javadoc + arguments: :alfred-api-interface:build :alfred-api-interface:javadoc - name: Unit test REST API uses: gradle/gradle-build-action@v2.4.2 with: - arguments: --info :apix-rest:test + arguments: --info :alfred-api-rest:test - name: Publish if: ${{ startsWith(github.ref, 'refs/heads/master') || startsWith(github.ref, 'refs/heads/release') }}" uses: gradle/gradle-build-action@v2.4.2 with: - arguments: --info -PsigningKeyId=DF8285F0 :apix-interface:publish + arguments: --info -PsigningKeyId=DF8285F0 :alfred-api-interface:publish - apix-impl: + alfred-api-impl: strategy: matrix: alfresco_version: [ 231, 232 ] @@ -66,8 +66,8 @@ jobs: with: arguments: >- --info - :apix-impl:apix-impl-${{ matrix.alfresco_version }}:test - :apix-integrationtests-client:alfresco:${{ matrix.alfresco_version }}:integrationTest + :alfred-api-impl:alfred-api-impl-${{ matrix.alfresco_version }}:test + :alfred-api-integrationtests-client:alfresco:${{ matrix.alfresco_version }}:integrationTest - name: Publish Test Report uses: mikepenz/action-junit-report@v3.7.6 if: success() || failure() diff --git a/.gitignore b/.gitignore index 00cc7f49..c74929d2 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ # Generated version file -apix-impl/src/main/java/eu/xenit/alfred/api/Version.java +alfred-api-impl/src/main/java/eu/xenit/alfred/api/Version.java target/ *.iml diff --git a/CHANGELOG.md b/CHANGELOG.md index 4d10a1f0..8d0547b6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,16 +5,17 @@ From this version onward Dynamic Extensions for integration-testing is replaced by [remote-junit](https://github.com/ruediste/remote-junit) as framework to reduce maintenance efforts. -A subproject with the name of `apix-integrationtests-server` has been added. (See README) -The artifact name of `apix-integrationtests` has been changed to `apix-integrationtests-client`. +A subproject with the name of `alfred-api-integrationtests-server` has been added. (See README) +The artifact name of `alfred-api-integrationtests` has been changed to `alfred-api-integrationtests-client`. **Breaking changes:** * JDK11 --> JDK 17 * Library changes from Javax to Jakarta * Tomcat V10.1: this comes with a breaking change in the dispatchservlet, blocking the MultiPart handling and blocks double forward slashes - * Fix has to be deployed from your tomcat image. You will have to update your META-INF/context.xml in tomcat. See subproject apix-docker. + * Fix has to be deployed from your tomcat image. You will have to update your META-INF/context.xml in tomcat. See subproject alfred-api-docker. * Dropped all support for older Alfresco version prior to V23.1 just as alfresco-mvc * **All package names have been updated from `eu.xenit.apix` to `eu.xenit.alfred.api`.** + * **All class names have been updated from `apix-...` to `alfred.api-...`.** * [ALFREDAPI-548](https://xenitsupport.jira.com/browse/ALFREDAPI-548): Support Alfresco V23.1 && V23.2, dropping V7.x * [ALFREDAPI-556](https://xenitsupport.jira.com/browse/ALFREDAPI-556): Change apix package-names to `eu.xenit.alfred.api`. diff --git a/README.md b/README.md index b232b97e..01edee09 100644 --- a/README.md +++ b/README.md @@ -39,15 +39,15 @@ Full documentation can be found at the [project's documentation](https://docs.xe * Follow our [coding styleguide and other active procedures](https://xenitsupport.jira.com/wiki/spaces/XEN/pages/624558081/XeniT+Enhancement+Proposals+XEP). ### Project structure -* *apix-interface* builds the interface of Alfred API. This part is agnostic of the +* *alfred-api-interface* builds the interface of Alfred API. This part is agnostic of the Alfresco version used. -* *apix-rest* builds the REST API of Alfred API. -* *apix-impl* builds the Java code for each version of Alfresco. +* *alfred-api-rest* builds the REST API of Alfred API. +* *alfred-api-impl* builds the Java code for each version of Alfresco. * *alfresco* builds the AMP for each Alfresco version that is the main deliverable for Alfred API. The AMP contains - the JARs of *apix-interface* and *apix-rest*. + the JARs of *alfred-api-interface* and *alfred-api-rest*. * *alfresco/xx* contains the correct properties for each Alfresco version. -* *apix-integrationtests-client* contains the integration tests for each Alfresco version. -* *apix-integrationtests-server* contains the Remote-JUnit runner for remote class loading. +* *alfred-api-integrationtests-client* contains the integration tests for each Alfresco version. +* *alfred-api-integrationtests-server* contains the Remote-JUnit runner for remote class loading. * uses java serialization and HTTP for communication. * We startup a CodeRunnerStandaloneServer, which starts a nanohttpd server, listening on a specific port (4578 by default) * Using a static appicationContext to reach all necessary beans. @@ -59,14 +59,14 @@ Alfresco version used. The following command starts up all docker containers required for an Alfresco running Alfred API. ```bash -./gradlew :apix-docker:docker-${VERSION}:composeUp --info +./gradlew :alfred-api-docker:docker-${VERSION}:composeUp --info ``` Where `VERSION` is e.g. `231`. #### Run integration tests ```bash -./gradlew :apix-integrationtests-client:alfresco:${VERSION}:integrationTest +./gradlew :alfred-api-integrationtests-client:alfresco:${VERSION}:integrationTest ``` Again, where `VERSION` is e.g. `231`. @@ -74,16 +74,16 @@ However, this starts (and afterwards stops) docker containers. This includes sta adding a startup time of several minutes. To circumvent this you also run the test on already running containers with for example: ```bash -./gradlew -x composeUp -x composeDown :apix-integrationtests-client:alfresco:231:integrationTest -Pprotocol=http -Phost=localhost -Pport=8074 +./gradlew -x composeUp -x composeDown :alfred-api-integrationtests-client:alfresco:231:integrationTest -Pprotocol=http -Phost=localhost -Pport=8074 ``` If you only want to run specific tests, you can specify this on the Gradle invocation with a pattern. For example: ```bash -./gradlew :apix-integrationtests-client:alfresco:231:integrationTest -x composeDown --tests ContentServiceTestJavaApi.TestContentUrlExists +./gradlew :alfred-api-integrationtests-client:alfresco:231:integrationTest -x composeDown --tests ContentServiceTestJavaApi.TestContentUrlExists ``` #### Run integration tests under debugger -1. Debugging settings are already added by `apix-docker/${VERSION}/debug-extension.docker-compose.yml`, including a +1. Debugging settings are already added by `alfred-api-docker/${VERSION}/debug-extension.docker-compose.yml`, including a portmapping `8000:8000`. This file does not get loaded when running in CI. 2. Prepare your remote debugger in IntelliJ and set breakpoints where you want in your tests (or Alfred API code). diff --git a/apix-docker/231/build.gradle b/alfred-api-docker/231/build.gradle similarity index 100% rename from apix-docker/231/build.gradle rename to alfred-api-docker/231/build.gradle diff --git a/apix-docker/231/debug-extension.docker-compose.yml b/alfred-api-docker/231/debug-extension.docker-compose.yml similarity index 100% rename from apix-docker/231/debug-extension.docker-compose.yml rename to alfred-api-docker/231/debug-extension.docker-compose.yml diff --git a/apix-docker/231/docker-compose.yml b/alfred-api-docker/231/docker-compose.yml similarity index 100% rename from apix-docker/231/docker-compose.yml rename to alfred-api-docker/231/docker-compose.yml diff --git a/apix-docker/232/build.gradle b/alfred-api-docker/232/build.gradle similarity index 100% rename from apix-docker/232/build.gradle rename to alfred-api-docker/232/build.gradle diff --git a/apix-docker/232/debug-extension.docker-compose.yml b/alfred-api-docker/232/debug-extension.docker-compose.yml similarity index 100% rename from apix-docker/232/debug-extension.docker-compose.yml rename to alfred-api-docker/232/debug-extension.docker-compose.yml diff --git a/apix-docker/232/docker-compose.yml b/alfred-api-docker/232/docker-compose.yml similarity index 100% rename from apix-docker/232/docker-compose.yml rename to alfred-api-docker/232/docker-compose.yml diff --git a/apix-docker/build.gradle b/alfred-api-docker/build.gradle similarity index 86% rename from apix-docker/build.gradle rename to alfred-api-docker/build.gradle index bdb7c401..c930d133 100644 --- a/apix-docker/build.gradle +++ b/alfred-api-docker/build.gradle @@ -13,9 +13,9 @@ subprojects { dependencies { alfrescoAmp project(path: ":alfresco:${subproject_alfresco_version}", configuration: 'ampArtifact') // Read in the alfresco V 23.x in with alfred-api amps - alfrescoAmp project(path: ":apix-integrationtests-server", configuration: 'amp') + alfrescoAmp project(path: ":alfred-api-integrationtests-server", configuration: 'amp') // Read in the alfresco integration-test-server - alfrescoAmp project(path: ':apix-integrationtests-client:model-amp', configuration: 'ampArchives') + alfrescoAmp project(path: ':alfred-api-integrationtests-client:model-amp', configuration: 'ampArchives') // Read the model in for running the integration tests. alfrescoSM "com.gradecak.alfresco-mvc:alfresco-mvc-rest:${mvc}" alfrescoSM "com.gradecak.alfresco-mvc:alfresco-mvc-aop:${mvc}" diff --git a/apix-impl/231/.gitkeep b/alfred-api-impl/231/.gitkeep similarity index 100% rename from apix-impl/231/.gitkeep rename to alfred-api-impl/231/.gitkeep diff --git a/apix-impl/232/.gitkeep b/alfred-api-impl/232/.gitkeep similarity index 100% rename from apix-impl/232/.gitkeep rename to alfred-api-impl/232/.gitkeep diff --git a/apix-impl/build.gradle b/alfred-api-impl/build.gradle similarity index 86% rename from apix-impl/build.gradle rename to alfred-api-impl/build.gradle index aac6df79..cda8394d 100644 --- a/apix-impl/build.gradle +++ b/alfred-api-impl/build.gradle @@ -1,9 +1,9 @@ subprojects { apply plugin: 'java-library' - // ::apix-impl cannot be set in allprojects due to circular dependency issues + // ::alfred-api-impl cannot be set in allprojects due to circular dependency issues dependencies { - api(project(":apix-impl")) + api(project(":alfred-api-impl")) } sourceSets { @@ -23,15 +23,15 @@ subprojects { allprojects { // Subproject of supported Alfresco versions - def subproject_alfresco_version = project.projectDir.name == "apix-impl" + def subproject_alfresco_version = project.projectDir.name == "alfred-api-impl" ? "231" : project.projectDir.name apply from: "$rootProject.projectDir/alfresco/${subproject_alfresco_version}/overrides.gradle" - // allprojects also applies to shared code (under apix-impl/src) that needs to work in IntelliJ + // allprojects also applies to shared code (under alfred-api-impl/src) that needs to work in IntelliJ apply plugin: 'eu.xenit.alfresco' apply plugin: 'java-library' dependencies { - api project(":apix-interface") + api project(":alfred-api-interface") implementation group: 'jakarta.validation', name: 'jakarta.validation-api', version: '3.0.0' implementation group: 'jakarta.annotation', name: 'jakarta.annotation-api', version: '3.0.0' @@ -64,7 +64,7 @@ allprojects { } task generateVersionFile(type: Task) { - def versionFile = "${rootDir}/apix-impl/src/main/java/eu/xenit/alfred/api/Version.java" + def versionFile = "${rootDir}/alfred-api-impl/src/main/java/eu/xenit/alfred/api/Version.java" outputs.file versionFile doFirst { file(versionFile).text = """package eu.xenit.alfred.api; diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/SpringConfiguration.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/SpringConfiguration.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/SpringConfiguration.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/SpringConfiguration.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/ApixSpringConfiguration.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/AlfredApiSpringConfiguration.java similarity index 94% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/ApixSpringConfiguration.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/AlfredApiSpringConfiguration.java index 535dabb2..688664ba 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/ApixSpringConfiguration.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/AlfredApiSpringConfiguration.java @@ -18,9 +18,9 @@ * Components based on Alfresco version are wired in eu.xenit.alfred.api.alfrescoXX.SpringConfiguration (where XX is version) */ @Configuration -public class ApixSpringConfiguration { +public class AlfredApiSpringConfiguration { - private final Logger logger = LoggerFactory.getLogger(ApixSpringConfiguration.class); + private final Logger logger = LoggerFactory.getLogger(AlfredApiSpringConfiguration.class); /** * Properties read from this AMP's 'alfresco-global.properties' file, exposed as a bean by Alfresco. diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/ApixToAlfrescoConversion.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/AlfredApiToAlfrescoConversion.java similarity index 64% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/ApixToAlfrescoConversion.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/AlfredApiToAlfrescoConversion.java index 259fb913..72b72f72 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/ApixToAlfrescoConversion.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/AlfredApiToAlfrescoConversion.java @@ -19,16 +19,16 @@ import org.springframework.stereotype.Component; -@Component("eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion") -public class ApixToAlfrescoConversion { +@Component("eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion") +public class AlfredApiToAlfrescoConversion { - private static final Logger logger = LoggerFactory.getLogger(ApixToAlfrescoConversion.class); + private static final Logger logger = LoggerFactory.getLogger(AlfredApiToAlfrescoConversion.class); private final String qnameRegex = "^(\\{.+\\}.+)$"; private final Pattern qnamePattern = Pattern.compile(qnameRegex); private NamespaceService namespaceService; @Autowired - public ApixToAlfrescoConversion(ServiceRegistry serviceRegistry) { + public AlfredApiToAlfrescoConversion(ServiceRegistry serviceRegistry) { this.namespaceService = serviceRegistry.getNamespaceService(); } @@ -40,55 +40,55 @@ public StoreRef alfresco(eu.xenit.alfred.api.data.StoreRef obj) { return new StoreRef(obj.getValue()); } - public eu.xenit.alfred.api.data.NodeRef apix(NodeRef obj) { + public eu.xenit.alfred.api.data.NodeRef alfredApi(NodeRef obj) { if (obj == null) { return null; } return new eu.xenit.alfred.api.data.NodeRef(obj.toString()); } - public List apix(List obj) { - //return obj.stream().map(n->apix(n)).collect(Collectors.toList()); - List apixNodes = new ArrayList<>(obj.size()); + public List alfredApi(List obj) { + //return obj.stream().map(n->alfredApi(n)).collect(Collectors.toList()); + List alfredApiNodes = new ArrayList<>(obj.size()); for (NodeRef alfNode : obj) { - apixNodes.add(apix(alfNode)); + alfredApiNodes.add(alfredApi(alfNode)); } - return apixNodes; + return alfredApiNodes; } -// public org.alfresco.repo.forms.Item alfresco(Item apixItem){ -// return new org.alfresco.repo.forms.Item(apixItem.getKind(), apixItem.getId()); +// public org.alfresco.repo.forms.Item alfresco(Item alfredApiItem){ +// return new org.alfresco.repo.forms.Item(alfredApiItem.getKind(), alfredApiItem.getId()); // } // -// public org.alfresco.repo.forms.FormData alfresco(FormData apixFormData){ +// public org.alfresco.repo.forms.FormData alfresco(FormData alfredApiFormData){ // org.alfresco.repo.forms.FormData alfFormData = new org.alfresco.repo.forms.FormData(); -// Map apixFieldDataMap = apixFormData.getAllFieldData(); -// Set apixFieldNames = apixFieldDataMap.keySet(); +// Map alfredApiFieldDataMap = alfredApiFormData.getAllFieldData(); +// Set alfredApiFieldNames = alfredApiFieldDataMap.keySet(); // -// for(String apixFieldName : apixFieldNames){ -// FieldData apixFieldData = apixFieldDataMap.get(apixFieldName); -// alfFormData.addFieldData(apixFieldData.getName(), apixFieldData.getValue()); +// for(String alfredApiFieldName : alfredApiFieldNames){ +// FieldData alfredApiFieldData = alfredApiFieldDataMap.get(alfredApiFieldName); +// alfFormData.addFieldData(alfredApiFieldData.getName(), alfredApiFieldData.getValue()); // } // // return alfFormData; // } - public Set apixNodeRefs(Set obj) { - Set apixNodes = new HashSet<>(obj.size()); + public Set alfredApiNodeRefs(Set obj) { + Set alfredApiNodes = new HashSet<>(obj.size()); for (NodeRef alfNode : obj) { - apixNodes.add(apix(alfNode)); + alfredApiNodes.add(alfredApi(alfNode)); } - return apixNodes; + return alfredApiNodes; } public List alfresco(List obj) { //return obj.stream().map(n->alfresco(n)).collect(Collectors.toList()); List alfNodes = new ArrayList<>(obj.size()); - for (eu.xenit.alfred.api.data.NodeRef apixNode : obj) { - alfNodes.add(alfresco(apixNode)); + for (eu.xenit.alfred.api.data.NodeRef alfredApiNode : obj) { + alfNodes.add(alfresco(alfredApiNode)); } return alfNodes; @@ -104,9 +104,9 @@ public Set alfresco(Set s) { } else if (first instanceof eu.xenit.alfred.api.data.QName) { return alfrescoQNames(s); } else if (first instanceof NodeRef) { - return apixNodeRefs(s); + return alfredApiNodeRefs(s); } else if (first instanceof QName) { - return apixQNames(s); + return alfredApiQNames(s); } else { throw new UnsupportedOperationException( "Unable to convertQuery Set<" + first.getClass().getName() + ">, class is not supported."); @@ -116,8 +116,8 @@ public Set alfresco(Set s) { public Set alfrescoNoderefs(Set obj) { Set alfNodes = new HashSet<>(obj.size()); - for (eu.xenit.alfred.api.data.NodeRef apixNode : obj) { - alfNodes.add(alfresco(apixNode)); + for (eu.xenit.alfred.api.data.NodeRef alfredApiNode : obj) { + alfNodes.add(alfresco(alfredApiNode)); } return alfNodes; @@ -134,10 +134,10 @@ public boolean HasAlfrescoQname(eu.xenit.alfred.api.data.QName qName) { } } - public boolean HasApixQname(org.alfresco.service.namespace.QName qName) { + public boolean HasAlfredApiQname(org.alfresco.service.namespace.QName qName) { try { - eu.xenit.alfred.api.data.QName apixName = apix(qName); - return apixName != null; + eu.xenit.alfred.api.data.QName alfredApiName = alfredApi(qName); + return alfredApiName != null; } catch (Exception e) { logger.debug("Qname does not exist: " + qName); logger.debug(e.toString()); @@ -173,23 +173,23 @@ public Path alfresco(eu.xenit.alfred.api.data.Path obj) { public Set alfrescoQNames(Set obj) { Set alfQnames = new HashSet<>(obj.size()); - for (eu.xenit.alfred.api.data.QName apixQname : obj) { - alfQnames.add(alfresco(apixQname)); + for (eu.xenit.alfred.api.data.QName alfredApiQname : obj) { + alfQnames.add(alfresco(alfredApiQname)); } return alfQnames; } - public Set apixQNames(Set obj) { - Set apixQnames = new HashSet<>(obj.size()); + public Set alfredApiQNames(Set obj) { + Set alfredApiQnames = new HashSet<>(obj.size()); for (QName qname : obj) { - apixQnames.add(apix(qname)); + alfredApiQnames.add(alfredApi(qname)); } - return apixQnames; + return alfredApiQnames; } - public eu.xenit.alfred.api.data.QName apix(QName obj) { + public eu.xenit.alfred.api.data.QName alfredApi(QName obj) { return new eu.xenit.alfred.api.data.QName(obj.toString()); } } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/PackageBeanNameGenerator.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/PackageBeanNameGenerator.java similarity index 91% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/PackageBeanNameGenerator.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/PackageBeanNameGenerator.java index 587afa1d..4614361a 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/PackageBeanNameGenerator.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/PackageBeanNameGenerator.java @@ -5,7 +5,7 @@ import org.springframework.beans.factory.support.BeanNameGenerator; /** - * Used to specify the full name + package for autowired (@Component) beans Currently only for the amp version of apix, + * Used to specify the full name + package for autowired (@Component) beans Currently only for the amp version of alfredApi, * not for the DE version Created by Michiel Huygen on 19/04/2016. */ public class PackageBeanNameGenerator implements BeanNameGenerator { diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/WIP/WIPServiceImpl.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/WIP/WIPServiceImpl.java similarity index 85% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/WIP/WIPServiceImpl.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/WIP/WIPServiceImpl.java index 6259aadb..6ac8ec55 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/WIP/WIPServiceImpl.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/WIP/WIPServiceImpl.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.alfresco.WIP; import eu.xenit.alfred.api.WIP.IWIPService; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import org.alfresco.service.ServiceRegistry; import org.alfresco.service.cmr.workflow.WorkflowService; import org.slf4j.Logger; @@ -16,12 +16,12 @@ public class WIPServiceImpl implements IWIPService { private final static Logger logger = LoggerFactory.getLogger(WIPServiceImpl.class); - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; private WorkflowService wf; private ServiceRegistry serviceRegistry; @Autowired - public void setC(ApixToAlfrescoConversion c) { + public void setC(AlfredApiToAlfrescoConversion c) { this.c = c; } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/categories/CategoryService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/categories/CategoryService.java similarity index 95% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/categories/CategoryService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/categories/CategoryService.java index 71063170..05c3157a 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/categories/CategoryService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/categories/CategoryService.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.alfresco.categories; import com.google.common.collect.Iterables; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.categories.Category; import eu.xenit.alfred.api.categories.ICategoryService; import java.io.Serializable; @@ -24,7 +24,7 @@ public class CategoryService implements ICategoryService { @Autowired - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; @Autowired private NodeService nodeService; @Autowired @@ -35,11 +35,11 @@ public class CategoryService implements ICategoryService { public CategoryService() { } - public CategoryService(ServiceRegistry registry, ApixToAlfrescoConversion apixToAlfrescoConversion) { + public CategoryService(ServiceRegistry registry, AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion) { nodeService = registry.getNodeService(); categoryService = registry.getCategoryService(); namespaceService = registry.getNamespaceService(); - c = apixToAlfrescoConversion; + c = alfredApiToAlfrescoConversion; } /** diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/comments/CommentService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/comments/CommentService.java similarity index 86% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/comments/CommentService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/comments/CommentService.java index 7c91d535..6a98633d 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/comments/CommentService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/comments/CommentService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.comments; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.comments.Comment; import eu.xenit.alfred.api.comments.Conversation; import eu.xenit.alfred.api.comments.ICommentService; @@ -33,27 +33,27 @@ public class CommentService implements ICommentService { protected IContentService contentService; protected INodeService nodeService; protected IPermissionService permissionService; - protected ApixToAlfrescoConversion apixConverter; + protected AlfredApiToAlfrescoConversion alfredApiConverter; @Autowired public CommentService(org.alfresco.repo.forum.CommentService commentService, IContentService contentService, - INodeService nodeService, IPermissionService permissionService, ApixToAlfrescoConversion apixConverter) { + INodeService nodeService, IPermissionService permissionService, AlfredApiToAlfrescoConversion alfredApiConverter) { this.commentService = commentService; this.contentService = contentService; this.nodeService = nodeService; this.permissionService = permissionService; - this.apixConverter = apixConverter; + this.alfredApiConverter = alfredApiConverter; } @Override public NodeRef getTargetDocumentForComment(NodeRef commentNodeRef) { - return apixConverter.apix(commentService.getDiscussableAncestor(apixConverter.alfresco(commentNodeRef))); + return alfredApiConverter.alfredApi(commentService.getDiscussableAncestor(alfredApiConverter.alfresco(commentNodeRef))); } @Override public Conversation getComments(NodeRef targetNode, int skipCount, int pageSize) { - org.alfresco.service.cmr.repository.NodeRef alfTargetNode = apixConverter.alfresco(targetNode); + org.alfresco.service.cmr.repository.NodeRef alfTargetNode = alfredApiConverter.alfresco(targetNode); PagingResults commentAlfNodes = commentService.listComments(alfTargetNode, new PagingRequest(skipCount, pageSize)); return new Conversation( @@ -66,12 +66,12 @@ public Conversation getComments(NodeRef targetNode, int skipCount, int pageSize) @Override public Comment getComment(NodeRef commentNode) { NodeRef alfTargetNode = getTargetDocumentForComment(commentNode); - return toComment(apixConverter.alfresco(alfTargetNode), apixConverter.alfresco(commentNode)); + return toComment(alfredApiConverter.alfresco(alfTargetNode), alfredApiConverter.alfresco(commentNode)); } @Override public Comment addNewComment(NodeRef targetNode, String content) { - org.alfresco.service.cmr.repository.NodeRef alfTargetNode = apixConverter.alfresco(targetNode); + org.alfresco.service.cmr.repository.NodeRef alfTargetNode = alfredApiConverter.alfresco(targetNode); return toComment(alfTargetNode, commentService.createComment(alfTargetNode, "", content, false)); } @@ -82,15 +82,15 @@ public Comment updateComment(NodeRef targetCommentNode, String content) { @Override public Comment updateComment(NodeRef targetDocumentNode, NodeRef targetCommentNode, String content) { - org.alfresco.service.cmr.repository.NodeRef alfTargetCommentNode = apixConverter.alfresco(targetCommentNode); + org.alfresco.service.cmr.repository.NodeRef alfTargetCommentNode = alfredApiConverter.alfresco(targetCommentNode); commentService.updateComment(alfTargetCommentNode, "", content); - org.alfresco.service.cmr.repository.NodeRef alfTargetDocumentNode = apixConverter.alfresco(targetDocumentNode); + org.alfresco.service.cmr.repository.NodeRef alfTargetDocumentNode = alfredApiConverter.alfresco(targetDocumentNode); return toComment(alfTargetDocumentNode, alfTargetCommentNode); } @Override public void deleteComment(NodeRef targetCommentNode) { - commentService.deleteComment(apixConverter.alfresco(targetCommentNode)); + commentService.deleteComment(alfredApiConverter.alfresco(targetCommentNode)); } @Override @@ -100,17 +100,17 @@ public boolean canCreateComment(NodeRef targetNodeRef) { protected Comment toComment(org.alfresco.service.cmr.repository.NodeRef documentNode, org.alfresco.service.cmr.repository.NodeRef commentNodeRef) { - NodeRef apixCommentNodeRef = apixConverter.apix(commentNodeRef); - NodeMetadata commentMetadata = nodeService.getMetadata(apixCommentNodeRef); + NodeRef alfredApiCommentNodeRef = alfredApiConverter.alfredApi(commentNodeRef); + NodeMetadata commentMetadata = nodeService.getMetadata(alfredApiCommentNodeRef); String content; try { - content = IOUtils.toString(contentService.getContent(apixCommentNodeRef).getInputStream()); + content = IOUtils.toString(contentService.getContent(alfredApiCommentNodeRef).getInputStream()); } catch (IOException e) { String message = String.format("Encountered an IOException while handling comment %s", commentNodeRef); throw new AlfrescoRuntimeException(message, e); } Comment response = new Comment(); - response.setId(apixCommentNodeRef); + response.setId(alfredApiCommentNodeRef); response.setContent(content); List property = commentMetadata.getProperties().get(new QName(ContentModel.PROP_TITLE.toString())); if (property != null && !property.isEmpty()) { diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/configuration/ConfigurationServiceImpl.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/configuration/ConfigurationServiceImpl.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/configuration/ConfigurationServiceImpl.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/configuration/ConfigurationServiceImpl.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/content/ContentService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/content/ContentService.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/content/ContentService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/content/ContentService.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/AspectService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/AspectService.java similarity index 85% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/AspectService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/AspectService.java index bd14df63..252d16af 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/AspectService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/AspectService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.dictionary; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.dictionary.aspects.AspectDefinition; import eu.xenit.alfred.api.dictionary.aspects.Aspects; @@ -20,10 +20,10 @@ public class AspectService implements IAspectService { private static final Logger logger = LoggerFactory.getLogger(AspectService.class); private DictionaryService dictionaryService; - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; @Autowired - public AspectService(DictionaryService dictionaryService, ApixToAlfrescoConversion c) { + public AspectService(DictionaryService dictionaryService, AlfredApiToAlfrescoConversion c) { this.dictionaryService = dictionaryService; this.c = c; } @@ -34,19 +34,19 @@ private AspectDefinition GetAspectDefinition(org.alfresco.service.namespace.QNam } org.alfresco.service.cmr.dictionary.AspectDefinition aspectDef = dictionaryService.getAspect(qname); AspectDefinition ret = new AspectDefinition(); - ret.setName(c.apix(aspectDef.getName())); + ret.setName(c.alfredApi(aspectDef.getName())); if (aspectDef.getParentName() != null) { - ret.setParent(c.apix(aspectDef.getParentName())); + ret.setParent(c.alfredApi(aspectDef.getParentName())); } ret.setDescription(aspectDef.getDescription(dictionaryService)); ret.setTitle(aspectDef.getTitle(dictionaryService)); List properties = new ArrayList<>(); for (org.alfresco.service.namespace.QName qName : aspectDef.getProperties().keySet()) { - properties.add(c.apix((qName))); + properties.add(c.alfredApi((qName))); } ret.setProperties(properties); List mandatoryAspects = aspectDef.getDefaultAspects().stream() - .map(aspectDefinition -> c.apix(aspectDefinition.getName())) + .map(aspectDefinition -> c.alfredApi(aspectDefinition.getName())) .collect(Collectors.toList()); ret.setMandatoryAspects(mandatoryAspects); return ret; @@ -77,7 +77,7 @@ public Aspects getAspects() { private boolean HasAspectDefinition(org.alfresco.service.namespace.QName qname) { try { - if (!c.HasApixQname(qname)) { + if (!c.HasAlfredApiQname(qname)) { return false; } org.alfresco.service.cmr.dictionary.AspectDefinition aspectDef = dictionaryService.getAspect(qname); diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/DictionaryService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/DictionaryService.java similarity index 97% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/DictionaryService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/DictionaryService.java index be85d0eb..413a9453 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/DictionaryService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/DictionaryService.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.alfresco.dictionary; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.dictionary.IDictionaryService; import eu.xenit.alfred.api.dictionary.aspects.AspectDefinition; import eu.xenit.alfred.api.dictionary.aspects.Aspects; @@ -39,7 +39,7 @@ public class DictionaryService implements IDictionaryService { private static final Logger logger = LoggerFactory.getLogger(DictionaryService.class); @Autowired - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; @Autowired private org.alfresco.service.cmr.dictionary.DictionaryService dictionaryService; diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyService.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyService.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyTypeCheckService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyTypeCheckService.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyTypeCheckService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/PropertyTypeCheckService.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/TypeService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/TypeService.java similarity index 87% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/TypeService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/TypeService.java index 57aab6f9..0d6f0c1d 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/TypeService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/dictionary/TypeService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.dictionary; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.dictionary.types.ITypeService; import eu.xenit.alfred.api.dictionary.types.TypeDefinition; @@ -21,10 +21,10 @@ public class TypeService implements ITypeService { private static final Logger logger = LoggerFactory.getLogger(TypeService.class); private DictionaryService dictionaryService; - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; @Autowired - public TypeService(DictionaryService dictionaryService, ApixToAlfrescoConversion c) { + public TypeService(DictionaryService dictionaryService, AlfredApiToAlfrescoConversion c) { this.dictionaryService = dictionaryService; this.c = c; } @@ -53,19 +53,19 @@ private TypeDefinition GetTypeDefinition(org.alfresco.service.namespace.QName qn } TypeDefinition ret = new TypeDefinition(); - ret.setName(c.apix(typeDef.getName())); + ret.setName(c.alfredApi(typeDef.getName())); if (typeDef.getParentName() != null) { - ret.setParent(c.apix(typeDef.getParentName())); + ret.setParent(c.alfredApi(typeDef.getParentName())); } ret.setDescription(typeDef.getDescription(dictionaryService)); ret.setTitle(typeDef.getTitle(dictionaryService)); List properties = new ArrayList<>(); for (org.alfresco.service.namespace.QName qName : typeDef.getProperties().keySet()) { - properties.add(c.apix((qName))); + properties.add(c.alfredApi((qName))); } ret.setProperties(properties); List mandatoryAspects = typeDef.getDefaultAspects().stream() - .map(aspectDefinition -> c.apix(aspectDefinition.getName())) + .map(aspectDefinition -> c.alfredApi(aspectDefinition.getName())) .collect(Collectors.toList()); ret.setMandatoryAspects(mandatoryAspects); return ret; diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/filefolder/FileFolderService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/filefolder/FileFolderService.java similarity index 90% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/filefolder/FileFolderService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/filefolder/FileFolderService.java index 70dbc54b..1dac6b5e 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/filefolder/FileFolderService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/filefolder/FileFolderService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.filefolder; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.NodeRef; import eu.xenit.alfred.api.data.StoreRef; import eu.xenit.alfred.api.filefolder.IFileFolderService; @@ -33,7 +33,7 @@ public class FileFolderService implements IFileFolderService { private final static Logger logger = LoggerFactory.getLogger(FileFolderService.class); private static final String DEFAULT_PROTOCOL = "workspace"; private static final String DEFAULT_STORE = "SpacesStore"; - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; private NodeService nodeService; private PermissionService permissionService; private NamespaceService nameSpaceService; @@ -43,7 +43,7 @@ public class FileFolderService implements IFileFolderService { private DictionaryService dictionaryService; @Autowired - public FileFolderService(ServiceRegistry serviceRegistry, ApixToAlfrescoConversion apixToAlfrescoConversion) { + public FileFolderService(ServiceRegistry serviceRegistry, AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion) { this.nodeService = serviceRegistry.getNodeService(); this.nameSpaceService = serviceRegistry.getNamespaceService(); this.permissionService = serviceRegistry.getPermissionService(); @@ -52,7 +52,7 @@ public FileFolderService(ServiceRegistry serviceRegistry, ApixToAlfrescoConversi this.fileFolderService = serviceRegistry.getFileFolderService(); this.dictionaryService = serviceRegistry.getDictionaryService(); - this.c = apixToAlfrescoConversion; + this.c = alfredApiToAlfrescoConversion; } @Override @@ -64,7 +64,7 @@ public NodeRef getCompanyHome() { .createQName(NamespaceService.APP_MODEL_1_0_URI, "company_home"); List assocRefs = nodeService .getChildAssocs(c.alfresco(rootNodeRef), ContentModel.ASSOC_CHILDREN, qname); - return c.apix(assocRefs.get(0).getChildRef()); + return c.alfredApi(assocRefs.get(0).getChildRef()); } @Override @@ -74,7 +74,7 @@ public NodeRef getDataDictionary() { QName qname = QName.createQName(NamespaceService.APP_MODEL_1_0_URI, "dictionary"); List assocRefs = nodeService .getChildAssocs(companyHome, ContentModel.ASSOC_CONTAINS, qname); - return c.apix(assocRefs.get(0).getChildRef()); + return c.alfredApi(assocRefs.get(0).getChildRef()); } @Override @@ -91,7 +91,7 @@ public NodePath getPath(NodeRef nodeRef) { @Override public NodeRef getRootFolder(StoreRef storeRef) { org.alfresco.service.cmr.repository.NodeRef result = this.nodeService.getRootNode(c.alfresco(storeRef)); - return c.apix(result); + return c.alfredApi(result); } @Override @@ -108,7 +108,7 @@ public boolean existsFolder(NodeRef parent, String name) { public NodeRef getChildNodeRef(NodeRef parent, String name) { try { FileInfo result = this.fileFolderService.resolveNamePath(c.alfresco(parent), Arrays.asList(name)); - return c.apix(result.getNodeRef()); + return c.alfredApi(result.getNodeRef()); } catch (FileNotFoundException e) { throw new InvalidArgumentException(String.format("Folder '%s' doesn't exist!", name)); } @@ -118,7 +118,7 @@ public NodeRef getChildNodeRef(NodeRef parent, String name) { public NodeRef getChildNodeRef(NodeRef parent, String[] path) { try { FileInfo result = this.fileFolderService.resolveNamePath(c.alfresco(parent), Arrays.asList(path)); - return c.apix(result.getNodeRef()); + return c.alfredApi(result.getNodeRef()); } catch (FileNotFoundException e) { throw new InvalidArgumentException( String.format("Folder '%s' doesn't exist!", StringUtils.join("/", path))); @@ -128,7 +128,7 @@ public NodeRef getChildNodeRef(NodeRef parent, String[] path) { @Override public NodeRef createFolder(NodeRef parent, String folderName) { FileInfo result = this.fileFolderService.create(c.alfresco(parent), folderName, ContentModel.TYPE_FOLDER); - return c.apix(result.getNodeRef()); + return c.alfredApi(result.getNodeRef()); } @Override diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/AlfrescoPropertyConvertor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/AlfrescoPropertyConvertor.java similarity index 96% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/AlfrescoPropertyConvertor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/AlfrescoPropertyConvertor.java index dc0d7c6e..8307c6ff 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/AlfrescoPropertyConvertor.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/AlfrescoPropertyConvertor.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.metadata; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import java.io.Serializable; import java.util.ArrayList; import java.util.Collection; @@ -27,12 +27,12 @@ public class AlfrescoPropertyConvertor { private final static Logger logger = LoggerFactory.getLogger(AlfrescoPropertyConvertor.class); - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; private DictionaryService dictionaryService; @Autowired - public AlfrescoPropertyConvertor(DictionaryService dictionaryService, ApixToAlfrescoConversion c) { + public AlfrescoPropertyConvertor(DictionaryService dictionaryService, AlfredApiToAlfrescoConversion c) { this.dictionaryService = dictionaryService; this.c = c; } @@ -60,7 +60,7 @@ public Pair> toModelPropertyValue( org.alfresco.service.namespace.QName alfQName, Serializable data) throws Exception { TypeConverter typeConverter = DefaultTypeConverter.INSTANCE; - eu.xenit.alfred.api.data.QName propQName = c.apix(alfQName); + eu.xenit.alfred.api.data.QName propQName = c.alfredApi(alfQName); if (data == null) { return new Pair<>(propQName, null); } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/DelayedInputStream.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/DelayedInputStream.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/DelayedInputStream.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/DelayedInputStream.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/NodeService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/NodeService.java similarity index 93% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/NodeService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/NodeService.java index 78f339ee..a7a5a16b 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/NodeService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/metadata/NodeService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.metadata; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.ContentInputStream; import eu.xenit.alfred.api.data.StoreRef; import eu.xenit.alfred.api.node.ChildParentAssociation; @@ -71,7 +71,7 @@ public class NodeService implements INodeService { private final static String NAMESPACE_BEGIN = "" + '{'; private final static Logger logger = LoggerFactory.getLogger(NodeService.class); - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; @Autowired private NamespaceService namespaceService; @Autowired @@ -98,14 +98,14 @@ public class NodeService implements INodeService { public NodeService() { } - public NodeService(ServiceRegistry serviceRegistry, ApixToAlfrescoConversion apixToAlfrescoConversion) { - this.c = apixToAlfrescoConversion; + public NodeService(ServiceRegistry serviceRegistry, AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion) { + this.c = alfredApiToAlfrescoConversion; this.serviceRegistry = serviceRegistry; - InitializeServices(serviceRegistry, apixToAlfrescoConversion); + InitializeServices(serviceRegistry, alfredApiToAlfrescoConversion); } @Autowired - public void setC(ApixToAlfrescoConversion c) { + public void setC(AlfredApiToAlfrescoConversion c) { this.c = c; if (this.serviceRegistry != null) { InitializeServices(serviceRegistry, c); @@ -125,7 +125,7 @@ public void setServiceRegistry(ServiceRegistry serviceRegistry) { } private void InitializeServices(ServiceRegistry serviceRegistry, - ApixToAlfrescoConversion apixToAlfrescoConversion) { + AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion) { permissionService = serviceRegistry.getPermissionService(); dictionaryService = serviceRegistry.getDictionaryService(); copyService = serviceRegistry.getCopyService(); @@ -137,7 +137,7 @@ private void InitializeServices(ServiceRegistry serviceRegistry, authenticationService = serviceRegistry.getAuthenticationService(); searchService = serviceRegistry.getSearchService(); contentService = serviceRegistry.getContentService(); - propertyConvertor = new AlfrescoPropertyConvertor(dictionaryService, apixToAlfrescoConversion); + propertyConvertor = new AlfrescoPropertyConvertor(dictionaryService, alfredApiToAlfrescoConversion); mimetypeService = serviceRegistry.getMimetypeService(); } @@ -169,7 +169,7 @@ public NodeMetadata getMetadata(eu.xenit.alfred.api.data.NodeRef noderef) { Map properties = this.nodeService.getProperties(alfNodeRef); - eu.xenit.alfred.api.data.QName type = c.apix(nodeService.getType(alfNodeRef)); + eu.xenit.alfred.api.data.QName type = c.alfredApi(nodeService.getType(alfNodeRef)); eu.xenit.alfred.api.data.QName baseType = getBaseType(type); logger.debug("baseType: " + baseType); @@ -183,14 +183,14 @@ public NodeMetadata getMetadata(eu.xenit.alfred.api.data.NodeRef noderef) { Set aspects = nodeService.getAspects(alfNodeRef); List metaAspects = new ArrayList<>(aspects.size()); for (QName qName : aspects) { - metaAspects.add(c.apix(qName)); + metaAspects.add(c.alfredApi(qName)); } return new NodeMetadata(noderef, type, baseType, transactionId, metaProperties, metaAspects); } public eu.xenit.alfred.api.data.NodeRef getRootNode(StoreRef storeRef) { - return c.apix(nodeService.getRootNode(c.alfresco(storeRef))); + return c.alfredApi(nodeService.getRootNode(c.alfresco(storeRef))); } @@ -212,7 +212,7 @@ private eu.xenit.alfred.api.data.QName getBaseType(eu.xenit.alfred.api.data.QNam ret = parentTypeName; } - return c.apix(ret); + return c.alfredApi(ret); } private boolean isNullOrTypeBase(eu.xenit.alfred.api.data.QName type) { @@ -261,7 +261,7 @@ public NodeMetadata setMetadata(eu.xenit.alfred.api.data.NodeRef noderef, Metada nodeService.setType(alfNode, newTypeQName); if (metadata.hasCleanUpAspectsOnGeneralization() && dictionaryService .isSubClass(oldTypeQName, newTypeQName)) { - cleanupAspects(noderef, c.apix(oldTypeQName), c.apix(newTypeQName)); + cleanupAspects(noderef, c.alfredApi(oldTypeQName), c.alfredApi(newTypeQName)); } } } @@ -377,8 +377,8 @@ public List getChildAssociations(eu.xenit.alfred.api.dat .stream().map(alfChildAssoc -> new ChildParentAssociation( ref, - c.apix(alfChildAssoc.getChildRef()), - c.apix(alfChildAssoc.getTypeQName()), + c.alfredApi(alfChildAssoc.getChildRef()), + c.alfredApi(alfChildAssoc.getTypeQName()), alfChildAssoc.isPrimary() )) .collect(Collectors.toList()); @@ -390,8 +390,8 @@ public List getParentAssociations(eu.xenit.alfred.api.da .stream().map(alfParentAssoc -> new ChildParentAssociation( ref, - c.apix(alfParentAssoc.getParentRef()), - c.apix(alfParentAssoc.getTypeQName()), + c.alfredApi(alfParentAssoc.getParentRef()), + c.alfredApi(alfParentAssoc.getTypeQName()), alfParentAssoc.isPrimary() )) .collect(Collectors.toList()); @@ -404,8 +404,8 @@ public List getTargetAssociations(eu.xenit.alfred.api.data.Node .map(alfPeerAssoc -> new NodeAssociation( ref, - c.apix(alfPeerAssoc.getTargetRef()), - c.apix(alfPeerAssoc.getTypeQName()))) + c.alfredApi(alfPeerAssoc.getTargetRef()), + c.alfredApi(alfPeerAssoc.getTypeQName()))) .collect(Collectors.toList()); } @@ -419,9 +419,9 @@ public List getSourceAssociations(eu.xenit.alfred.api.data.Node .stream() .map(alfPeerAssoc -> new NodeAssociation( - c.apix(alfPeerAssoc.getSourceRef()), + c.alfredApi(alfPeerAssoc.getSourceRef()), ref, - c.apix(alfPeerAssoc.getTypeQName()))) + c.alfredApi(alfPeerAssoc.getTypeQName()))) .collect(Collectors.toList()); } @@ -459,7 +459,7 @@ public List getAncestors(eu.xenit.alfred.api.d ChildAssociationRef childAssocRef = nodeService.getPrimaryParent(nodeRef); NodeRef parentRef = childAssocRef.getParentRef(); while (parentRef != null) { - ancestorRefs.add(c.apix(parentRef)); + ancestorRefs.add(c.alfredApi(parentRef)); if (parentRef.equals(alfrescoRootRef)) { break; } @@ -554,7 +554,7 @@ public eu.xenit.alfred.api.data.NodeRef copyNode(eu.xenit.alfred.api.data.NodeRe c.alfresco(destination), ContentModel.ASSOC_CONTAINS, (QName) null, deepCopy); - return c.apix(copyRef); + return c.alfredApi(copyRef); } @Override @@ -565,7 +565,7 @@ public eu.xenit.alfred.api.data.NodeRef moveNode(eu.xenit.alfred.api.data.NodeRe c.alfresco(destination), ContentModel.ASSOC_CONTAINS, primaryParentAssoc.getQName()); - return c.apix(childAssoc.getChildRef()); + return c.alfredApi(childAssoc.getChildRef()); } @Override @@ -581,7 +581,7 @@ public eu.xenit.alfred.api.data.NodeRef createNode(eu.xenit.alfred.api.data.Node throw new InvalidArgumentException("Type cannot be null!"); } FileInfo createdNode = fileFolderService.create(c.alfresco(parent), name, c.alfresco(type)); - return c.apix(createdNode.getNodeRef()); + return c.alfredApi(createdNode.getNodeRef()); } @Override @@ -596,7 +596,7 @@ public eu.xenit.alfred.api.data.NodeRef createNode(eu.xenit.alfred.api.data.Node Map properties, eu.xenit.alfred.api.data.QName[] aspectsToAdd, eu.xenit.alfred.api.data.QName[] aspectsToRemove, eu.xenit.alfred.api.data.QName type, eu.xenit.alfred.api.data.ContentData contentData) { - String[] names = properties.get(c.apix(ContentModel.PROP_NAME)); + String[] names = properties.get(c.alfredApi(ContentModel.PROP_NAME)); if (names == null || names.length == 0) { throw new InvalidArgumentException( String.format("mandatory property %s is missing in properties", ContentModel.PROP_NAME)); @@ -615,7 +615,7 @@ public eu.xenit.alfred.api.data.NodeRef createNode(eu.xenit.alfred.api.data.Node MetadataChanges aspects = new MetadataChanges(); aspects.setAspectsToAdd(aspectsToAdd); aspects.setAspectsToRemove(aspectsToRemove); - setMetadata(c.apix(result.getChildRef()), aspects); + setMetadata(c.alfredApi(result.getChildRef()), aspects); if (contentData != null) { this.nodeService.setProperty(result.getChildRef(), ContentModel.PROP_CONTENT, c.alfresco(contentData)); @@ -624,7 +624,7 @@ public eu.xenit.alfred.api.data.NodeRef createNode(eu.xenit.alfred.api.data.Node throw new InvalidArgumentException("Node with same name already exists in parent!"); } - return c.apix(result.getChildRef()); + return c.alfredApi(result.getChildRef()); } @@ -768,10 +768,10 @@ public eu.xenit.alfred.api.data.NodeRef checkout(eu.xenit.alfred.api.data.NodeRe } if (destination == null) { - workingCopy = c.apix(this.checkoutCheckinService.checkout(c.alfresco(original))); + workingCopy = c.alfredApi(this.checkoutCheckinService.checkout(c.alfresco(original))); } else { ChildAssociationRef childAssocRef = this.nodeService.getPrimaryParent(c.alfresco(destination)); - workingCopy = c.apix(this.checkoutCheckinService.checkout(c.alfresco(original), + workingCopy = c.alfredApi(this.checkoutCheckinService.checkout(c.alfresco(original), c.alfresco(destination), ContentModel.ASSOC_CONTAINS, childAssocRef.getQName())); @@ -787,7 +787,7 @@ public eu.xenit.alfred.api.data.NodeRef checkin(eu.xenit.alfred.api.data.NodeRef props.put("description", comment); props.put("versionType", majorVersion ? VersionType.MAJOR : VersionType.MINOR); - eu.xenit.alfred.api.data.NodeRef original = c.apix(this.checkoutCheckinService.checkin(c.alfresco(nodeRef), props)); + eu.xenit.alfred.api.data.NodeRef original = c.alfredApi(this.checkoutCheckinService.checkin(c.alfresco(nodeRef), props)); return original; } @@ -795,13 +795,13 @@ public eu.xenit.alfred.api.data.NodeRef checkin(eu.xenit.alfred.api.data.NodeRef @Override public eu.xenit.alfred.api.data.NodeRef cancelCheckout(eu.xenit.alfred.api.data.NodeRef workingCopyRef) { NodeRef original = this.checkoutCheckinService.cancelCheckout(c.alfresco(workingCopyRef)); - return c.apix(original); + return c.alfredApi(original); } @Override public eu.xenit.alfred.api.data.NodeRef getWorkingCopySource(eu.xenit.alfred.api.data.NodeRef workingCopyRef) { NodeRef originalRef = this.checkoutCheckinService.getCheckedOut(c.alfresco(workingCopyRef)); - return c.apix(originalRef); + return c.alfredApi(originalRef); } @Override diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/people/PeopleService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/people/PeopleService.java similarity index 93% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/people/PeopleService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/people/PeopleService.java index 1563d96e..52ce095b 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/people/PeopleService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/people/PeopleService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.people; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.NodeRef; import eu.xenit.alfred.api.groups.Group; import eu.xenit.alfred.api.people.IPeopleService; @@ -32,18 +32,18 @@ public class PeopleService implements IPeopleService { private static final Logger logger = LoggerFactory.getLogger(PeopleService.class); - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; private PersonService alfrescoPersonService; private NodeService nodeService; private AuthorityService authorityService; private ServiceRegistry serviceRegistry; @Autowired - public PeopleService(PersonService personService, ApixToAlfrescoConversion apixToAlfrescoConversion, + public PeopleService(PersonService personService, AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion, NodeService nodeService, ServiceRegistry serviceRegistry) { this.alfrescoPersonService = personService; this.nodeService = nodeService; - this.c = apixToAlfrescoConversion; + this.c = alfredApiToAlfrescoConversion; this.authorityService = serviceRegistry.getAuthorityService(); this.serviceRegistry = serviceRegistry; } @@ -62,7 +62,7 @@ public Person GetPerson(NodeRef nodeRef) throws IllegalArgumentException, NoSuch Set groupsSet = authorityService.getContainingAuthorities(AuthorityType.GROUP, username, false); List groups = new ArrayList(groupsSet); String emailAddress = (String) nodeService.getProperty(info.getNodeRef(), ContentModel.PROP_EMAIL); - NodeRef ref = c.apix(info.getNodeRef()); + NodeRef ref = c.alfredApi(info.getNodeRef()); return new Person(ref, info.getUserName(), info.getFirstName(), info.getLastName(), emailAddress, groups); } @@ -79,7 +79,7 @@ public List GetPeople() { people.add(personInfo.getNodeRef()); } for (org.alfresco.service.cmr.repository.NodeRef personNodeRef : people) { - Person p = GetPerson(c.apix(personNodeRef)); + Person p = GetPerson(c.alfredApi(personNodeRef)); ret.add(p); } return ret; @@ -130,7 +130,7 @@ public Person GetPerson(String userName) throws IllegalArgumentException, NoSuch throw new IllegalArgumentException("Username cannot be null or empty"); } String normalizedUserName = normalizeUserName(userName); - NodeRef personRef = c.apix(alfrescoPersonService.getPersonOrNull(normalizedUserName)); + NodeRef personRef = c.alfredApi(alfrescoPersonService.getPersonOrNull(normalizedUserName)); if (personRef == null) { throw new NoSuchElementException("User " + normalizedUserName + " does not exist"); } @@ -140,7 +140,7 @@ public Person GetPerson(String userName) throws IllegalArgumentException, NoSuch @Override public Group GetGroup(String groupIdentifier) { String displayName = authorityService.getAuthorityDisplayName(groupIdentifier); - NodeRef nodeRef = c.apix(authorityService.getAuthorityNodeRef(groupIdentifier)); + NodeRef nodeRef = c.alfredApi(authorityService.getAuthorityNodeRef(groupIdentifier)); return new Group(nodeRef, groupIdentifier, displayName); } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/PermissionService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/PermissionService.java similarity index 97% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/PermissionService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/PermissionService.java index fc6c585c..4969e02f 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/PermissionService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/PermissionService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.permissions; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.NodeRef; import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.permissions.IPermissionService; @@ -53,16 +53,16 @@ public class PermissionService implements IPermissionService { @Autowired public ModelDAO modelDAO; private org.alfresco.service.cmr.security.PermissionService permissionService; - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; private Map fullControlPermissions = new HashMap(); @Autowired - public PermissionService(ServiceRegistry serviceRegistry, ApixToAlfrescoConversion apixToAlfrescoConversion) { + public PermissionService(ServiceRegistry serviceRegistry, AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion) { this.permissionService = serviceRegistry.getPermissionService(); for (String permissionString : this.permissionStrings) { this.fullControlPermissions.put(permissionString, PermissionValue.ALLOW); } - this.c = apixToAlfrescoConversion; + this.c = alfredApiToAlfrescoConversion; } private synchronized Set getAllRegisteredPermissions() { @@ -255,7 +255,7 @@ public Map getPermissions(NodeRef node) { continue; } AccessStatus accessStatus = this.permissionService.hasPermission(c.alfresco(node), permString); - // Translate from Alfresco enums to apix enums + // Translate from Alfresco enums to alfredApi enums switch (accessStatus) { case ALLOWED: result.put(permString, PermissionValue.ALLOW); diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/RolePermissionModel.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/RolePermissionModel.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/RolePermissionModel.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/permissions/RolePermissionModel.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/properties/PropertyServiceImpl.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/properties/PropertyServiceImpl.java similarity index 89% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/properties/PropertyServiceImpl.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/properties/PropertyServiceImpl.java index ee7f51c2..6d84d534 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/properties/PropertyServiceImpl.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/properties/PropertyServiceImpl.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.properties; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.dictionary.properties.IPropertyService; import eu.xenit.alfred.api.properties.Properties; @@ -31,10 +31,10 @@ public class PropertyServiceImpl implements IPropertyService { private static final Logger logger = LoggerFactory.getLogger(PropertyServiceImpl.class); protected DictionaryService dictionaryService; private MessageService messageService; - protected ApixToAlfrescoConversion c; + protected AlfredApiToAlfrescoConversion c; @Autowired - public PropertyServiceImpl(DictionaryService dictionaryService, ApixToAlfrescoConversion c, + public PropertyServiceImpl(DictionaryService dictionaryService, AlfredApiToAlfrescoConversion c, MessageService messageService) { this.dictionaryService = dictionaryService; this.c = c; @@ -46,10 +46,10 @@ public PropertyIndexOptions GetPropertyIndexOptions(PropertyDefinition definitio return null; } PropertyIndexOptions IndexOptions = new PropertyIndexOptions(); - IndexOptions.setFacetable(FacetableFromApix(definition.getFacetable())); + IndexOptions.setFacetable(FacetableFromAlfredApi(definition.getFacetable())); IndexOptions.setStored(definition.isStoredInIndex()); IndexTokenisationMode tokenisationMode = definition.getIndexTokenisationMode(); - IndexOptions.setTokenised(TokenisedFromApix(tokenisationMode)); + IndexOptions.setTokenised(TokenisedFromAlfredApi(tokenisationMode)); return IndexOptions; } @@ -57,10 +57,10 @@ private eu.xenit.alfred.api.properties.PropertyDefinition propertyDefinitionCons PropertyDefinition definition) { eu.xenit.alfred.api.properties.PropertyDefinition propertyDefinitionUnderConstruction = new eu.xenit.alfred.api.properties.PropertyDefinition( - c.apix(definition.getName()), c.apix(definition.getContainerClass().getName()), + c.alfredApi(definition.getName()), c.alfredApi(definition.getContainerClass().getName()), definition.getTitle(messageService), definition.getDescription(messageService), definition.getDefaultValue(), - c.apix(definition.getDataType().getName()), definition.isMultiValued(), definition.isMandatory(), + c.alfredApi(definition.getDataType().getName()), definition.isMultiValued(), definition.isMandatory(), definition.isMandatoryEnforced(), definition.isProtected(), this.GetPropertyIndexOptions(definition), this.GetConstraints(definition)); @@ -130,7 +130,7 @@ private List GetConstraints(PropertyDefinition def return constraintsUnderConstruction; } - private static PropertyFacetable FacetableFromApix(Facetable facetable) { + private static PropertyFacetable FacetableFromAlfredApi(Facetable facetable) { switch (facetable) { case FALSE: return PropertyFacetable.FALSE.FALSE; @@ -141,7 +141,7 @@ private static PropertyFacetable FacetableFromApix(Facetable facetable) { } } - private PropertyTokenised TokenisedFromApix(IndexTokenisationMode tokMode) { + private PropertyTokenised TokenisedFromAlfredApi(IndexTokenisationMode tokMode) { switch (tokMode) { case FALSE: return PropertyTokenised.FALSE; diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitor.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitor.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitor.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitor.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsService.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsService.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsServiceImpl.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsServiceImpl.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsServiceImpl.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchFacetsServiceImpl.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchResultCountService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchResultCountService.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchResultCountService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchResultCountService.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchService.java similarity index 97% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchService.java index 5c37f81c..02ab1128 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/search/SearchService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.search; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.alfresco.dictionary.PropertyService; import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.search.FacetSearchResult; @@ -36,16 +36,16 @@ public class SearchService implements ISearchService { public static final int MAX_ITEMS_DEFAULT = 1000; private static final Logger logger = LoggerFactory.getLogger(SearchService.class); protected SearchFacetsService facetService; - protected ApixToAlfrescoConversion c; + protected AlfredApiToAlfrescoConversion c; protected org.alfresco.service.cmr.search.SearchService searchService; protected PropertyService propertyService; @Autowired public SearchService(org.alfresco.service.cmr.search.SearchService searchService, SearchFacetsService facetService, - ApixToAlfrescoConversion apixToAlfrescoConversion, PropertyService propertyService) { + AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion, PropertyService propertyService) { this.searchService = searchService; this.facetService = facetService; - this.c = apixToAlfrescoConversion; + this.c = alfredApiToAlfrescoConversion; this.propertyService = propertyService; } @@ -165,7 +165,7 @@ public SearchParameters buildSearchParameters(SearchQuery postQuery) { * We do this because the alfresco/solr implementation of highlights, which takes the searchTerms or search query * and adds it in the querystring of the request between alfresco and solr. * This breaks when: - * There are no searchTerms in the query; Alfresco does not set these, and apix does not yet support these. + * There are no searchTerms in the query; Alfresco does not set these, and alfredApi does not yet support these. * AND * The query is too long; if there are no searchTerms given, alfresco will instead use the full search query to * add to the querystring. For long queries this might violate the url parameter length restriction (around 2000 @@ -234,7 +234,7 @@ protected SearchQueryResult processResults(ResultSet rs, SearchQuery postQuery, int count = 0; int maxItems = getSearchMaxItems(searchParameters); for (ResultSetRow row : rs) { - results.addResult(c.apix(row.getNodeRef())); + results.addResult(c.alfredApi(row.getNodeRef())); ++count; // maxItems < 0 means unlimited if (maxItems > 0 && count >= maxItems) { diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/Site.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/Site.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/Site.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/Site.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/SiteService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/SiteService.java similarity index 84% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/SiteService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/SiteService.java index c9109277..9d07fe31 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/SiteService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/sites/SiteService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.sites; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.NodeRef; import eu.xenit.alfred.api.sites.ISite; import eu.xenit.alfred.api.sites.ISiteService; @@ -26,24 +26,24 @@ public class SiteService implements ISiteService { private final static String WIKI_COMPONENT = "wiki"; private final static String DISCUSSIONS_COMPONENT = "discussions"; - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; private ServiceRegistry serviceRegistry; @Autowired - public SiteService(ServiceRegistry serviceRegistry, ApixToAlfrescoConversion apixToAlfrescoConversion) { + public SiteService(ServiceRegistry serviceRegistry, AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion) { this.serviceRegistry = serviceRegistry; - c = apixToAlfrescoConversion; + c = alfredApiToAlfrescoConversion; } public List getUserSites(String userId) { org.alfresco.service.cmr.site.SiteService siteService = serviceRegistry.getSiteService(); - List apixSites = new ArrayList<>(); + List alfredApiSites = new ArrayList<>(); List userSites = siteService.listSites(userId); for (SiteInfo userSite : userSites) { - NodeRef nodeRef = c.apix(userSite.getNodeRef()); + NodeRef nodeRef = c.alfredApi(userSite.getNodeRef()); String shortName = userSite.getShortName(); String title = userSite.getTitle(); String description = userSite.getDescription(); @@ -53,13 +53,13 @@ public List getUserSites(String userId) { // this caused the entire call to fail. try { Map componentsMap = getSiteComponents(siteService, shortName); - apixSites.add(new Site(nodeRef, shortName, title, description, isPublic, componentsMap)); + alfredApiSites.add(new Site(nodeRef, shortName, title, description, isPublic, componentsMap)); } catch (AccessDeniedException accessDeniedException) { logger.warn("User {} does not have access to a site component for site {} according to exception.", userId, shortName, accessDeniedException); } } - return apixSites; + return alfredApiSites; } private Map getSiteComponents(org.alfresco.service.cmr.site.SiteService siteService, String siteShortname) { @@ -76,7 +76,7 @@ private Map getSiteComponents(org.alfresco.service.cmr.site.Sit private void addSiteComponentToMap(org.alfresco.service.cmr.site.SiteService siteService, Map componentsMap, String siteShortname, String siteComponentName) { try { - NodeRef componentRef = c.apix(siteService.getContainer(siteShortname, siteComponentName)); + NodeRef componentRef = c.alfredApi(siteService.getContainer(siteShortname, siteComponentName)); if (componentRef == null) { return; } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/transaction/TransactionService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/transaction/TransactionService.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/transaction/TransactionService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/transaction/TransactionService.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/ResourceBundleTranslationKey.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/ResourceBundleTranslationKey.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/ResourceBundleTranslationKey.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/ResourceBundleTranslationKey.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/TranslationService.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/TranslationService.java similarity index 94% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/TranslationService.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/TranslationService.java index a5b72922..f58c1244 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/TranslationService.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/translation/TranslationService.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.translation; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.dictionary.IDictionaryService; import eu.xenit.alfred.api.translation.ITranslationService; import eu.xenit.alfred.api.translation.PropertyTranslationValue; @@ -48,20 +48,20 @@ public class TranslationService implements ITranslationService { private MessageService messageService; @Autowired - private IDictionaryService apixDictionaryservice; + private IDictionaryService alfredApiDictionaryservice; @Autowired - private ApixToAlfrescoConversion apixToAlfrescoConversion; + private AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion; public TranslationService() { } - public TranslationService(ServiceRegistry serviceRegistry, ApixToAlfrescoConversion apixToAlfrescoConversion, + public TranslationService(ServiceRegistry serviceRegistry, AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversion, IDictionaryService dictionaryService, MessageService messageService) { this.namespaceService = serviceRegistry.getNamespaceService(); this.alfDictionaryService = serviceRegistry.getDictionaryService(); - this.apixToAlfrescoConversion = apixToAlfrescoConversion; - this.apixDictionaryservice = dictionaryService; + this.alfredApiToAlfrescoConversion = alfredApiToAlfrescoConversion; + this.alfredApiDictionaryservice = dictionaryService; this.messageService = messageService; } @@ -74,7 +74,7 @@ public long getTranslationsCheckSum(Locale locale) { ObjectOutputStream oos = new ObjectOutputStream(bytesOut); - Long modelChecksum = apixDictionaryservice.getContentModelCheckSum(); + Long modelChecksum = alfredApiDictionaryservice.getContentModelCheckSum(); oos.writeBytes(modelChecksum.toString()); //TODO: this is not deterministic and might cause problems later @@ -212,7 +212,7 @@ private TranslationValue getTranslationValueObject(QName qname, Map versions = v.getAllVersions(); List vList = new ArrayList(); for (org.alfresco.service.cmr.version.Version version : versions) { - vList.add(VersionAlfrescoToApix(version)); + vList.add(VersionAlfrescoToAlfredApi(version)); } return new VersionHistory(vList); } - private Version VersionAlfrescoToApix(org.alfresco.service.cmr.version.Version version) { + private Version VersionAlfrescoToAlfredApi(org.alfresco.service.cmr.version.Version version) { String description = version.getDescription(); String versionLabel = version.getVersionLabel(); String modifier = version.getFrozenModifier(); @@ -63,7 +63,7 @@ private Version VersionAlfrescoToApix(org.alfresco.service.cmr.version.Version v Version ret = new Version(modifier, modified, versionLabel, description, vType, - c.apix(version.getFrozenStateNodeRef())); + c.alfredApi(version.getFrozenStateNodeRef())); return ret; } @@ -98,14 +98,14 @@ public void deleteVersion(NodeRef nodeRef, String versionLabel) { public Version getRootVersion(NodeRef nodeRef) { org.alfresco.service.cmr.version.Version alfVersion = alfrescoVersionHistoryService .getVersionHistory(c.alfresco(nodeRef)).getRootVersion(); - return VersionAlfrescoToApix(alfVersion); + return VersionAlfrescoToAlfredApi(alfVersion); } @Override public Version getHeadVersion(NodeRef nodeRef) { org.alfresco.service.cmr.version.Version alfVersion = alfrescoVersionHistoryService .getVersionHistory(c.alfresco(nodeRef)).getHeadVersion(); - return VersionAlfrescoToApix(alfVersion); + return VersionAlfrescoToAlfredApi(alfVersion); } @Override diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/web/WebUtils.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/web/WebUtils.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/web/WebUtils.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/web/WebUtils.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixAlfrescoWorkflowConvertor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiAlfrescoWorkflowConvertor.java similarity index 93% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixAlfrescoWorkflowConvertor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiAlfrescoWorkflowConvertor.java index c8b6b0cd..4570ca65 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixAlfrescoWorkflowConvertor.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiAlfrescoWorkflowConvertor.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.workflow.IWorkflowService; import eu.xenit.alfred.api.workflow.model.WorkflowOrTaskChanges; import java.io.Serializable; @@ -28,11 +28,11 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; -public abstract class AbstractApixAlfrescoWorkflowConvertor extends AbstractApixWorkflowConvertor { +public abstract class AbstractAlfredApiAlfrescoWorkflowConvertor extends AbstractAlfredApiWorkflowConvertor { protected static final QName QNAME_ASSIGNEE = QName.createQName(IWorkflowService.ALFRESCO_ASSIGNEE); protected static final QName QNAME_GROUP_ASSIGNEE = QName.createQName(IWorkflowService.ALFRESCO_GROUP_ASSIGNEE); - private static final Logger logger = LoggerFactory.getLogger(AbstractApixAlfrescoWorkflowConvertor.class); + private static final Logger logger = LoggerFactory.getLogger(AbstractAlfredApiAlfrescoWorkflowConvertor.class); private static final QName REVIEW_OUTCOME_PROPERTY = QName .createQName("http://www.alfresco.org/model/bpm/1.0", "outcomePropertyName"); private static final String LIST_CONSTRAINT = "listconstraint"; @@ -40,7 +40,7 @@ public abstract class AbstractApixAlfrescoWorkflowConvertor extends AbstractApix private static final String ALLOWED_VALUES = "allowedValues"; private static final QName ownerQName = QName.createQName(IWorkflowService.ALFRESCO_OWNER); private static final QName initiatorQName = QName.createQName(IWorkflowService.ALFRESCO_INITIATOR); - private static final Map ApixToAlfrescoNames = new HashMap() {{ + private static final Map AlfredApiToAlfrescoNames = new HashMap() {{ put(IWorkflowService.ALFRESCO_DUEDATE, IWorkflowService.ALFRESCO_DUEDATE); put(IWorkflowService.ALFRESCO_ENDDATE, IWorkflowService.ALFRESCO_ENDDATE); put(IWorkflowService.ALFRESCO_STARTDATE, IWorkflowService.ALFRESCO_STARTDATE); @@ -80,7 +80,7 @@ public abstract class AbstractApixAlfrescoWorkflowConvertor extends AbstractApix add(IWorkflowService.ALFRESCO_WORKFLOW_ID); }}; @Autowired - protected ApixToAlfrescoConversion c; + protected AlfredApiToAlfrescoConversion c; @Autowired @Qualifier("WorkflowService") protected WorkflowService workflowService; @@ -235,8 +235,8 @@ protected Map filterEditableProperties(WorkflowOrTaskChange continue; } - String normalizedPropertyName = ApixToAlfrescoNames.containsKey(property) ? - ApixToAlfrescoNames.get(property) : property; + String normalizedPropertyName = AlfredApiToAlfrescoNames.containsKey(property) ? + AlfredApiToAlfrescoNames.get(property) : property; String valueToNormalize = changes.getPropertiesToSet().get(property); Serializable normalizedValue = this.normalizePropertyValueToAlfresco(property, valueToNormalize); editableProperties @@ -255,30 +255,30 @@ private Serializable normalizePropertyValueToAlfresco(String propId, String valu } } - protected Map toApixProperties(Map props) { + protected Map toAlfredApiProperties(Map props) { HashMap ret = new HashMap<>(); for (QName property : props.keySet()) { if (property == null) { logger.error("Trying to convert properties with a null key."); } else { - ret.put(property.toString(), toApixPropertyValue(props.get(property))); + ret.put(property.toString(), toAlfredApiPropertyValue(props.get(property))); } } return ret; } - private Serializable toApixPropertyValue(Serializable value) { + private Serializable toAlfredApiPropertyValue(Serializable value) { if (value instanceof NodeRef) { NodeRef nodeRef = (NodeRef) value; - return c.apix(nodeRef); + return c.alfredApi(nodeRef); } if (value instanceof List) { ArrayList list = new ArrayList<>((List) value); ArrayList result = new ArrayList<>(); for (Serializable item : list) { - result.add(toApixPropertyValue(item)); + result.add(toAlfredApiPropertyValue(item)); } return result; } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixQueryConverter.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiQueryConverter.java similarity index 91% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixQueryConverter.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiQueryConverter.java index 1a4c4e1d..fca10783 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixQueryConverter.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiQueryConverter.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow; -import eu.xenit.alfred.api.alfresco.workflow.activiti.query.ApixHistoricInstanceQuery; +import eu.xenit.alfred.api.alfresco.workflow.activiti.query.AlfredApiHistoricInstanceQuery; import eu.xenit.alfred.api.alfresco.workflow.utils.DebugHelper; import eu.xenit.alfred.api.people.IPeopleService; import eu.xenit.alfred.api.workflow.model.ITaskOrWorkflow; @@ -16,9 +16,9 @@ import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; -public abstract class AbstractApixQueryConverter { +public abstract class AbstractAlfredApiQueryConverter { - private final Logger logger = LoggerFactory.getLogger(AbstractApixQueryConverter.class); + private final Logger logger = LoggerFactory.getLogger(AbstractAlfredApiQueryConverter.class); @Autowired private ServiceRegistry serviceRegistry; @@ -35,13 +35,13 @@ protected IPeopleService getPeopleService() { protected abstract ITaskOrWorkflow convert(T var1); - public abstract ApixHistoricInstanceQuery convertQuery(SearchQuery var1); + public abstract AlfredApiHistoricInstanceQuery convertQuery(SearchQuery var1); public abstract ITaskOrWorkflow get(String var1); public abstract void update(String var1, WorkflowOrTaskChanges var2); - protected void ApplySearchQuery(SearchQuery searchQuery, ApixHistoricInstanceQuery q) { + protected void ApplySearchQuery(SearchQuery searchQuery, AlfredApiHistoricInstanceQuery q) { q.setActive(searchQuery.isActive); q.filter(searchQuery.filters); q.orderBy(searchQuery.orderBy); diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixWorkflowConvertor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiWorkflowConvertor.java similarity index 95% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixWorkflowConvertor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiWorkflowConvertor.java index e9e528b6..f32e4ce8 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractApixWorkflowConvertor.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractAlfredApiWorkflowConvertor.java @@ -12,9 +12,9 @@ import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; -public abstract class AbstractApixWorkflowConvertor { +public abstract class AbstractAlfredApiWorkflowConvertor { - private static final Logger logger = LoggerFactory.getLogger(AbstractApixWorkflowConvertor.class); + private static final Logger logger = LoggerFactory.getLogger(AbstractAlfredApiWorkflowConvertor.class); @Autowired private IPeopleService peopleService; diff --git a/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractQueryConverterFactory.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractQueryConverterFactory.java new file mode 100644 index 00000000..5dfc8ecb --- /dev/null +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractQueryConverterFactory.java @@ -0,0 +1,8 @@ +package eu.xenit.alfred.api.alfresco.workflow; + +public interface AbstractQueryConverterFactory { + + AbstractAlfredApiQueryConverter getProcessQueryConverter(); + + AbstractAlfredApiQueryConverter getTasksQueryConverter(); +} diff --git a/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowConverterFactory.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowConverterFactory.java new file mode 100644 index 00000000..169584c7 --- /dev/null +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowConverterFactory.java @@ -0,0 +1,8 @@ +package eu.xenit.alfred.api.alfresco.workflow; + +public interface WorkflowConverterFactory { + + AbstractAlfredApiWorkflowConvertor getProcessInstanceConvertor(); + + AbstractAlfredApiWorkflowConvertor getTaskInstanceConvertor(); +} diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceActivitiImpl.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceActivitiImpl.java similarity index 82% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceActivitiImpl.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceActivitiImpl.java index 005ecae5..4ef12674 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceActivitiImpl.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceActivitiImpl.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.alfresco.workflow; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; -import eu.xenit.alfred.api.alfresco.workflow.activiti.query.ApixHistoricInstanceQuery; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.workflow.activiti.query.AlfredApiHistoricInstanceQuery; import eu.xenit.alfred.api.alfresco.workflow.utils.DebugHelper; import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.people.IPeopleService; @@ -45,15 +45,15 @@ public class WorkflowServiceActivitiImpl implements IWorkflowService, Initializi private AuthenticationService authenticationService; @Autowired - private ApixToAlfrescoConversion c; + private AlfredApiToAlfrescoConversion c; @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiQueryConverterFactory") @Autowired private AbstractQueryConverterFactory activitiQueryConverterFactory; - private AbstractApixQueryConverter apixWfTaskQueryConverter; + private AbstractAlfredApiQueryConverter alfredApiWfTaskQueryConverter; - private AbstractApixQueryConverter apixWfProcQueryConverter; + private AbstractAlfredApiQueryConverter alfredApiWfProcQueryConverter; @Autowired @Qualifier("WorkflowService") @@ -65,12 +65,12 @@ public void afterPropertiesSet() throws Exception { } public void init() { - this.apixWfProcQueryConverter = this.activitiQueryConverterFactory.getProcessQueryConverter(); - this.apixWfTaskQueryConverter = this.activitiQueryConverterFactory.getTasksQueryConverter(); + this.alfredApiWfProcQueryConverter = this.activitiQueryConverterFactory.getProcessQueryConverter(); + this.alfredApiWfTaskQueryConverter = this.activitiQueryConverterFactory.getTasksQueryConverter(); } public void GenerateWorkflows(int amount, String username) { - this.apixWfProcQueryConverter.generate(amount, username); + this.alfredApiWfProcQueryConverter.generate(amount, username); } @Override @@ -92,52 +92,52 @@ public List getAllDefinitions() { } private WorkflowDefinition convertDefinition(org.alfresco.service.cmr.workflow.WorkflowDefinition alfDef) { - WorkflowDefinition apixDef = new WorkflowDefinition(); + WorkflowDefinition alfredApiDef = new WorkflowDefinition(); - apixDef.id = alfDef.getId(); - apixDef.key = alfDef.getId().substring(0, alfDef.getId().indexOf(':')); - apixDef.name = alfDef.getName(); - apixDef.title = alfDef.getTitle(); - apixDef.description = alfDef.getDescription(); - apixDef.version = alfDef.getVersion(); + alfredApiDef.id = alfDef.getId(); + alfredApiDef.key = alfDef.getId().substring(0, alfDef.getId().indexOf(':')); + alfredApiDef.name = alfDef.getName(); + alfredApiDef.title = alfDef.getTitle(); + alfredApiDef.description = alfDef.getDescription(); + alfredApiDef.version = alfDef.getVersion(); - return apixDef; + return alfredApiDef; } public void endTask(String taskID, String transitionID) { - this.apixWfTaskQueryConverter.end(taskID, transitionID); + this.alfredApiWfTaskQueryConverter.end(taskID, transitionID); } public Task getTaskInfo(String taskID) { - return (Task) this.apixWfTaskQueryConverter.get(taskID); + return (Task) this.alfredApiWfTaskQueryConverter.get(taskID); } public Workflow getWorkflowInfo(String workflowID) { - return (Workflow) this.apixWfProcQueryConverter.get(workflowID); + return (Workflow) this.alfredApiWfProcQueryConverter.get(workflowID); } public Workflow updateWorkflow(String id, WorkflowOrTaskChanges changes) { - this.apixWfProcQueryConverter.update(id, changes); + this.alfredApiWfProcQueryConverter.update(id, changes); return this.getWorkflowInfo(id); } public Task updateTask(String id, WorkflowOrTaskChanges changes) { - this.apixWfTaskQueryConverter.update(id, changes); + this.alfredApiWfTaskQueryConverter.update(id, changes); return this.getTaskInfo(id); } public Task claimWorkflowTask(String taskID) { - this.apixWfTaskQueryConverter.claim(taskID); + this.alfredApiWfTaskQueryConverter.claim(taskID); return this.getTaskInfo(taskID); } public Task claimWorkflowTask(String taskID, String userName) { - this.apixWfTaskQueryConverter.claim(taskID, userName); + this.alfredApiWfTaskQueryConverter.claim(taskID, userName); return this.getTaskInfo(taskID); } public Task releaseWorkflowTask(String taskID) { - this.apixWfTaskQueryConverter.release(taskID); + this.alfredApiWfTaskQueryConverter.release(taskID); return this.getTaskInfo(taskID); } @@ -147,7 +147,7 @@ public TaskOrWorkflowSearchResult searchWorkflows(WorkflowSearchQuery searchQuer searchQuery.scope = QueryScope.AllWorkflows; } searchQuery.restrictResultsToUser(this.authenticationService.getCurrentUserName()); - return this.fetch(searchQuery, this.apixWfProcQueryConverter); + return this.fetch(searchQuery, this.alfredApiWfProcQueryConverter); } public TaskOrWorkflowSearchResult searchTasks(TaskSearchQuery searchQuery) { @@ -156,10 +156,10 @@ public TaskOrWorkflowSearchResult searchTasks(TaskSearchQuery searchQuery) { searchQuery.scope = TaskSearchQuery.QueryScope.AllTasks; } searchQuery.restrictResultsToUser(this.authenticationService.getCurrentUserName()); - return this.fetch(searchQuery, this.apixWfTaskQueryConverter); + return this.fetch(searchQuery, this.alfredApiWfTaskQueryConverter); } - private TaskOrWorkflowSearchResult fetch(TaskSearchQuery searchQuery, AbstractApixQueryConverter queryConverter) { + private TaskOrWorkflowSearchResult fetch(TaskSearchQuery searchQuery, AbstractAlfredApiQueryConverter queryConverter) { logger.debug("fetch Filters size: " + searchQuery.filters.size()); List result = TaskSearchQuery.QueryScope.MyPooledTasks == searchQuery.scope ? fetchMyPooledTasks(searchQuery, queryConverter) @@ -168,13 +168,13 @@ private TaskOrWorkflowSearchResult fetch(TaskSearchQuery searchQuery, AbstractAp } private TaskOrWorkflowSearchResult fetch(WorkflowSearchQuery searchQuery, - AbstractApixQueryConverter queryConverter) { + AbstractAlfredApiQueryConverter queryConverter) { return queryConverter .CreateSearchResult(fetchSingleQuery(searchQuery, queryConverter), searchQuery.includeResults, searchQuery.paging); } - private List fetchMyPooledTasks(TaskSearchQuery searchQuery, AbstractApixQueryConverter queryConverter) { + private List fetchMyPooledTasks(TaskSearchQuery searchQuery, AbstractAlfredApiQueryConverter queryConverter) { List result = new ArrayList<>(); List otherFilters = new ArrayList<>(); @@ -219,7 +219,7 @@ private List fetchMyPooledTasks(TaskSearchQuery searchQuery, AbstractApix } private List fetchSubQuery(IQueryFilter authFilter, List otherFilters, - TaskSearchQuery searchQuery, AbstractApixQueryConverter queryConverter) { + TaskSearchQuery searchQuery, AbstractAlfredApiQueryConverter queryConverter) { TaskSearchQuery userSubQuery = new TaskSearchQuery(searchQuery); userSubQuery.filters = new ArrayList<>(otherFilters); userSubQuery.filters.add(authFilter); @@ -238,10 +238,10 @@ private void filterAuthorities(SearchQuery searchQuery, List au } - private List fetchSingleQuery(SearchQuery searchQuery, AbstractApixQueryConverter queryConverter) { + private List fetchSingleQuery(SearchQuery searchQuery, AbstractAlfredApiQueryConverter queryConverter) { List result = new ArrayList<>(); long start = System.nanoTime(); - ApixHistoricInstanceQuery wq = queryConverter.convertQuery(searchQuery); + AlfredApiHistoricInstanceQuery wq = queryConverter.convertQuery(searchQuery); this.PrintCurrentTimeElapsed("dateFilteredWorkflows in: ", start); List queryResult = wq.getAll(); this.PrintCurrentTimeElapsed("dateFilteredWorkflows in: ", start); @@ -278,7 +278,7 @@ public Workflow startWorkflow(String definitionId, Map par } WorkflowPath wfPath = workflowService.startWorkflow(definitionId, convertedParams); - return (Workflow) this.apixWfProcQueryConverter.get(wfPath.getId()); + return (Workflow) this.alfredApiWfProcQueryConverter.get(wfPath.getId()); } private static boolean isNodeRef(Serializable value) { diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceApsImpl.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceApsImpl.java similarity index 97% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceApsImpl.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceApsImpl.java index 749da643..7e1b0e0a 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceApsImpl.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowServiceApsImpl.java @@ -4,7 +4,7 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.node.ObjectNode; -import eu.xenit.alfred.api.alfresco.ApixSpringConfiguration; +import eu.xenit.alfred.api.alfresco.AlfredApiSpringConfiguration; import eu.xenit.alfred.api.alfresco.workflow.aps.ApsFormDefinition; import eu.xenit.alfred.api.alfresco.workflow.aps.ApsFormField; import eu.xenit.alfred.api.data.QName; @@ -46,7 +46,7 @@ public class WorkflowServiceApsImpl implements IWorkflowService { @Autowired - private ApixSpringConfiguration configuration; + private AlfredApiSpringConfiguration configuration; private static final String APS_REST_DEFAULT_BASE_URL = "http://process-service:8080/activiti-app/api"; private static final String APS_REST_DEFAULT_USERNAME = "admin"; @@ -63,7 +63,7 @@ private HttpEntity doHttp(HttpUriRequest request) { HttpResponse response = httpClient.execute(request); int statusCode = response.getStatusLine().getStatusCode(); if (statusCode >= 300 || statusCode < 200) { - String errorMessage = String.format("Apix HttpClient encountered status \"%d: %s\" during %s %s", + String errorMessage = String.format("Alfred-Api HttpClient encountered status \"%d: %s\" during %s %s", statusCode, response.getStatusLine().getReasonPhrase(), request.getMethod(), request.getURI()); logger.error(errorMessage); throw new RuntimeException(errorMessage); @@ -71,7 +71,7 @@ private HttpEntity doHttp(HttpUriRequest request) { return response.getEntity(); } catch (IOException e) { - String errorMessage = String.format("Apix HttpClient encountered IOException during %s %s", + String errorMessage = String.format("Alfred-Api HttpClient encountered IOException during %s %s", request.getMethod(), request.getURI()); logger.error(errorMessage); throw new RuntimeException(errorMessage, e); diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiInstanceConverterFactory.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiInstanceConverterFactory.java similarity index 67% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiInstanceConverterFactory.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiInstanceConverterFactory.java index ee7ac735..ed926306 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiInstanceConverterFactory.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiInstanceConverterFactory.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow.activiti; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiWorkflowConvertor; import eu.xenit.alfred.api.alfresco.workflow.WorkflowConverterFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; @@ -11,17 +11,17 @@ public class ActivitiInstanceConverterFactory implements WorkflowConverterFactor @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiProcessInstanceWorkflowConvertor") @Autowired - protected AbstractApixWorkflowConvertor activitiProcessInstanceWorkflowConvertor; + protected AbstractAlfredApiWorkflowConvertor activitiProcessInstanceWorkflowConvertor; @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiWorkflowTaskWorkflowConvertor") @Autowired - protected AbstractApixWorkflowConvertor activitiWorkflowTaskWorkflowConvertor; + protected AbstractAlfredApiWorkflowConvertor activitiWorkflowTaskWorkflowConvertor; - public AbstractApixWorkflowConvertor getProcessInstanceConvertor() { + public AbstractAlfredApiWorkflowConvertor getProcessInstanceConvertor() { return this.activitiProcessInstanceWorkflowConvertor; } - public AbstractApixWorkflowConvertor getTaskInstanceConvertor() { + public AbstractAlfredApiWorkflowConvertor getTaskInstanceConvertor() { return this.activitiWorkflowTaskWorkflowConvertor; } } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiProcessInstanceWorkflowConvertor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiProcessInstanceWorkflowConvertor.java similarity index 91% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiProcessInstanceWorkflowConvertor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiProcessInstanceWorkflowConvertor.java index 83cdf3b5..2f9baa7c 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiProcessInstanceWorkflowConvertor.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiProcessInstanceWorkflowConvertor.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow.activiti; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiWorkflowConvertor; import eu.xenit.alfred.api.alfresco.workflow.WorkflowConverterFactory; import eu.xenit.alfred.api.workflow.model.ITaskOrWorkflow; import eu.xenit.alfred.api.workflow.model.WorkflowOrTaskChanges; @@ -10,14 +10,14 @@ import org.springframework.stereotype.Component; @Component("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiProcessInstanceWorkflowConvertor") -public class ActivitiProcessInstanceWorkflowConvertor extends AbstractApixWorkflowConvertor { +public class ActivitiProcessInstanceWorkflowConvertor extends AbstractAlfredApiWorkflowConvertor { @Qualifier("eu.xenit.alfred.api.alfresco.workflow.alfresco.AlfrescoInstanceConverterFactory") @Autowired protected WorkflowConverterFactory alfrescoWorkflowConverterFactory; - private AbstractApixWorkflowConvertor getConvertor() { + private AbstractAlfredApiWorkflowConvertor getConvertor() { return this.alfrescoWorkflowConverterFactory.getProcessInstanceConvertor(); } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiWorkflowTaskWorkflowConvertor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiWorkflowTaskWorkflowConvertor.java similarity index 91% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiWorkflowTaskWorkflowConvertor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiWorkflowTaskWorkflowConvertor.java index 5936b14f..1f605403 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiWorkflowTaskWorkflowConvertor.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/ActivitiWorkflowTaskWorkflowConvertor.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow.activiti; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiWorkflowConvertor; import eu.xenit.alfred.api.alfresco.workflow.WorkflowConverterFactory; import eu.xenit.alfred.api.workflow.model.ITaskOrWorkflow; import eu.xenit.alfred.api.workflow.model.WorkflowOrTaskChanges; @@ -10,7 +10,7 @@ import org.springframework.stereotype.Component; @Component("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiWorkflowTaskWorkflowConvertor") -public class ActivitiWorkflowTaskWorkflowConvertor extends AbstractApixWorkflowConvertor { +public class ActivitiWorkflowTaskWorkflowConvertor extends AbstractAlfredApiWorkflowConvertor { public static String ACTIVITI_PREFIX = "activiti$"; @@ -18,7 +18,7 @@ public class ActivitiWorkflowTaskWorkflowConvertor extends AbstractApixWorkflowC @Autowired protected WorkflowConverterFactory alfrescoWorkflowConverterFactory; - private AbstractApixWorkflowConvertor getConvertor() { + private AbstractAlfredApiWorkflowConvertor getConvertor() { return this.alfrescoWorkflowConverterFactory.getTaskInstanceConvertor(); } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ActivitiQueryConverterFactory.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ActivitiQueryConverterFactory.java similarity index 51% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ActivitiQueryConverterFactory.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ActivitiQueryConverterFactory.java index d46bb7cd..37bad948 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ActivitiQueryConverterFactory.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ActivitiQueryConverterFactory.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow.activiti.query; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixQueryConverter; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiQueryConverter; import eu.xenit.alfred.api.alfresco.workflow.AbstractQueryConverterFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; @@ -9,19 +9,19 @@ @Component("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiQueryConverterFactory") public class ActivitiQueryConverterFactory implements AbstractQueryConverterFactory { - @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.ApixActivitiWorkflowProcessQueryConverter") + @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.AlfredApiActivitiWorkflowProcessQueryConverter") @Autowired - protected AbstractApixQueryConverter apixActivitiWorkflowProcessQueryConverter; + protected AbstractAlfredApiQueryConverter alfredApiActivitiWorkflowProcessQueryConverter; - @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.ApixActivitiWorkflowTaskQueryConverter") + @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.AlfredApiActivitiWorkflowTaskQueryConverter") @Autowired - protected AbstractApixQueryConverter apixActivitiWorkflowTaskQueryConverter; + protected AbstractAlfredApiQueryConverter alfredApiActivitiWorkflowTaskQueryConverter; - public AbstractApixQueryConverter getProcessQueryConverter() { - return this.apixActivitiWorkflowProcessQueryConverter; + public AbstractAlfredApiQueryConverter getProcessQueryConverter() { + return this.alfredApiActivitiWorkflowProcessQueryConverter; } - public AbstractApixQueryConverter getTasksQueryConverter() { - return this.apixActivitiWorkflowTaskQueryConverter; + public AbstractAlfredApiQueryConverter getTasksQueryConverter() { + return this.alfredApiActivitiWorkflowTaskQueryConverter; } } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixActivitiWorkflowProcessQueryConverter.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiActivitiWorkflowProcessQueryConverter.java similarity index 73% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixActivitiWorkflowProcessQueryConverter.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiActivitiWorkflowProcessQueryConverter.java index c3da8627..9a196ea1 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixActivitiWorkflowProcessQueryConverter.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiActivitiWorkflowProcessQueryConverter.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.alfresco.workflow.activiti.query; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixQueryConverter; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiQueryConverter; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiWorkflowConvertor; import eu.xenit.alfred.api.alfresco.workflow.WorkflowConverterFactory; import eu.xenit.alfred.api.workflow.model.ITaskOrWorkflow; import eu.xenit.alfred.api.workflow.model.WorkflowOrTaskChanges; @@ -10,19 +10,19 @@ import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.stereotype.Component; -@Component("eu.xenit.alfred.api.alfresco.workflow.activiti.ApixActivitiWorkflowProcessQueryConverter") -public class ApixActivitiWorkflowProcessQueryConverter extends AbstractApixQueryConverter { +@Component("eu.xenit.alfred.api.alfresco.workflow.activiti.AlfredApiActivitiWorkflowProcessQueryConverter") +public class AlfredApiActivitiWorkflowProcessQueryConverter extends AbstractAlfredApiQueryConverter { @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiInstanceConverterFactory") @Autowired protected WorkflowConverterFactory abstractQueryConverterFactory; - private AbstractApixWorkflowConvertor getConvertor() { + private AbstractAlfredApiWorkflowConvertor getConvertor() { return this.abstractQueryConverterFactory.getProcessInstanceConvertor(); } - public ApixHistoricInstanceQuery convertQuery(SearchQuery searchQuery) { - ApixHistoricProcessInstanceQuery pq = new ApixHistoricProcessInstanceQuery(this.getServiceRegistry()); + public AlfredApiHistoricInstanceQuery convertQuery(SearchQuery searchQuery) { + AlfredApiHistoricProcessInstanceQuery pq = new AlfredApiHistoricProcessInstanceQuery(this.getServiceRegistry()); this.ApplySearchQuery(searchQuery, pq); return pq; } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixActivitiWorkflowTaskQueryConverter.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiActivitiWorkflowTaskQueryConverter.java similarity index 73% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixActivitiWorkflowTaskQueryConverter.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiActivitiWorkflowTaskQueryConverter.java index bccafa9a..98c8ba66 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixActivitiWorkflowTaskQueryConverter.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiActivitiWorkflowTaskQueryConverter.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.alfresco.workflow.activiti.query; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixQueryConverter; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiQueryConverter; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiWorkflowConvertor; import eu.xenit.alfred.api.alfresco.workflow.WorkflowConverterFactory; import eu.xenit.alfred.api.workflow.model.ITaskOrWorkflow; import eu.xenit.alfred.api.workflow.model.WorkflowOrTaskChanges; @@ -10,19 +10,19 @@ import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.stereotype.Component; -@Component("eu.xenit.alfred.api.alfresco.workflow.activiti.ApixActivitiWorkflowTaskQueryConverter") -public class ApixActivitiWorkflowTaskQueryConverter extends AbstractApixQueryConverter { +@Component("eu.xenit.alfred.api.alfresco.workflow.activiti.AlfredApiActivitiWorkflowTaskQueryConverter") +public class AlfredApiActivitiWorkflowTaskQueryConverter extends AbstractAlfredApiQueryConverter { @Qualifier("eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiInstanceConverterFactory") @Autowired private WorkflowConverterFactory abstractQueryConverterFactory; - private AbstractApixWorkflowConvertor getConvertor() { + private AbstractAlfredApiWorkflowConvertor getConvertor() { return this.abstractQueryConverterFactory.getTaskInstanceConvertor(); } - public ApixHistoricInstanceQuery convertQuery(SearchQuery searchQuery) { - ApixHistoricTaskInstanceQuery tq = new ApixHistoricTaskInstanceQuery(this.getServiceRegistry(), + public AlfredApiHistoricInstanceQuery convertQuery(SearchQuery searchQuery) { + AlfredApiHistoricTaskInstanceQuery tq = new AlfredApiHistoricTaskInstanceQuery(this.getServiceRegistry(), this.getPeopleService()); this.ApplySearchQuery(searchQuery, tq); return tq; diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricInstanceQuery.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricInstanceQuery.java similarity index 95% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricInstanceQuery.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricInstanceQuery.java index 63c8a36d..9d4f178e 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricInstanceQuery.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricInstanceQuery.java @@ -20,11 +20,11 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; -public abstract class ApixHistoricInstanceQuery { +public abstract class AlfredApiHistoricInstanceQuery { private static final QName historyServiceQName = QName.createQName((String) null, "activitiHistoryService"); private static final QName taskServiceQName = QName.createQName((String) null, "activitiTaskService"); - private final Logger logger = LoggerFactory.getLogger(ApixHistoricInstanceQuery.class); + private final Logger logger = LoggerFactory.getLogger(AlfredApiHistoricInstanceQuery.class); protected ServiceRegistry serviceRegistry; private HistoryService historyService; private NamespaceService namespaceService; @@ -33,7 +33,7 @@ public abstract class ApixHistoricInstanceQuery { private TaskService taskService; private AuthenticationService authenticationService; - public ApixHistoricInstanceQuery(ServiceRegistry serviceRegistry) { + public AlfredApiHistoricInstanceQuery(ServiceRegistry serviceRegistry) { this.serviceRegistry = serviceRegistry; init(); } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricProcessInstanceQuery.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricProcessInstanceQuery.java similarity index 95% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricProcessInstanceQuery.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricProcessInstanceQuery.java index e902d895..bb3c62a6 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricProcessInstanceQuery.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricProcessInstanceQuery.java @@ -12,12 +12,12 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; -public class ApixHistoricProcessInstanceQuery extends ApixHistoricInstanceQuery { +public class AlfredApiHistoricProcessInstanceQuery extends AlfredApiHistoricInstanceQuery { - private final Logger logger = LoggerFactory.getLogger(ApixHistoricProcessInstanceQuery.class); + private final Logger logger = LoggerFactory.getLogger(AlfredApiHistoricProcessInstanceQuery.class); private HistoricProcessInstanceQuery process; - ApixHistoricProcessInstanceQuery(ServiceRegistry serviceRegistry) { + AlfredApiHistoricProcessInstanceQuery(ServiceRegistry serviceRegistry) { super(serviceRegistry); this.process = this.getHistoryService().createHistoricProcessInstanceQuery(); } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricTaskInstanceQuery.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricTaskInstanceQuery.java similarity index 96% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricTaskInstanceQuery.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricTaskInstanceQuery.java index 1ca5d600..fec5e023 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/ApixHistoricTaskInstanceQuery.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/activiti/query/AlfredApiHistoricTaskInstanceQuery.java @@ -17,14 +17,14 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; -public class ApixHistoricTaskInstanceQuery extends ApixHistoricInstanceQuery { +public class AlfredApiHistoricTaskInstanceQuery extends AlfredApiHistoricInstanceQuery { - private final Logger logger = LoggerFactory.getLogger(ApixHistoricTaskInstanceQuery.class); + private final Logger logger = LoggerFactory.getLogger(AlfredApiHistoricTaskInstanceQuery.class); private TaskQuery task; private IPeopleService peopleService; - ApixHistoricTaskInstanceQuery(ServiceRegistry serviceRegistry, IPeopleService peopleService) { + AlfredApiHistoricTaskInstanceQuery(ServiceRegistry serviceRegistry, IPeopleService peopleService) { super(serviceRegistry); this.peopleService = peopleService; this.task = this.getTaskService().createTaskQuery(); diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoInstanceConverterFactory.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoInstanceConverterFactory.java similarity index 68% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoInstanceConverterFactory.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoInstanceConverterFactory.java index 4dac0053..ab63a611 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoInstanceConverterFactory.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoInstanceConverterFactory.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow.alfresco; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiWorkflowConvertor; import eu.xenit.alfred.api.alfresco.workflow.WorkflowConverterFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Qualifier; @@ -11,17 +11,17 @@ public class AlfrescoInstanceConverterFactory implements WorkflowConverterFactor @Qualifier("eu.xenit.alfred.api.alfresco.workflow.alfresco.AlfrescoProcessInstanceWorkflowConvertor") @Autowired - protected AbstractApixWorkflowConvertor processInstanceWorkflowConvertor; + protected AbstractAlfredApiWorkflowConvertor processInstanceWorkflowConvertor; @Qualifier("eu.xenit.alfred.api.alfresco.workflow.alfresco.AlfrescoWorkflowTaskWorkflowConvertor") @Autowired - protected AbstractApixWorkflowConvertor workflowTaskWorkflowConvertor; + protected AbstractAlfredApiWorkflowConvertor workflowTaskWorkflowConvertor; - public AbstractApixWorkflowConvertor getProcessInstanceConvertor() { + public AbstractAlfredApiWorkflowConvertor getProcessInstanceConvertor() { return this.processInstanceWorkflowConvertor; } - public AbstractApixWorkflowConvertor getTaskInstanceConvertor() { + public AbstractAlfredApiWorkflowConvertor getTaskInstanceConvertor() { return this.workflowTaskWorkflowConvertor; } } diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoProcessInstanceWorkflowConvertor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoProcessInstanceWorkflowConvertor.java similarity index 91% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoProcessInstanceWorkflowConvertor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoProcessInstanceWorkflowConvertor.java index 1c38d7ee..90af170a 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoProcessInstanceWorkflowConvertor.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoProcessInstanceWorkflowConvertor.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.alfresco.workflow.alfresco; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixAlfrescoWorkflowConvertor; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiAlfrescoWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiWorkflowConvertor; import eu.xenit.alfred.api.workflow.model.ITaskOrWorkflow; import eu.xenit.alfred.api.workflow.model.Task; import eu.xenit.alfred.api.workflow.model.Workflow; @@ -26,7 +26,7 @@ import org.springframework.stereotype.Component; @Component("eu.xenit.alfred.api.alfresco.workflow.alfresco.AlfrescoProcessInstanceWorkflowConvertor") -public class AlfrescoProcessInstanceWorkflowConvertor extends AbstractApixAlfrescoWorkflowConvertor { +public class AlfrescoProcessInstanceWorkflowConvertor extends AbstractAlfredApiAlfrescoWorkflowConvertor { private static final Logger logger = LoggerFactory.getLogger(AlfrescoProcessInstanceWorkflowConvertor.class); private static final Random random = new Random(); @@ -34,7 +34,7 @@ public class AlfrescoProcessInstanceWorkflowConvertor extends AbstractApixAlfres protected PersonService personService; @Autowired @Qualifier("eu.xenit.alfred.api.alfresco.workflow.alfresco.AlfrescoWorkflowTaskWorkflowConvertor") - protected AbstractApixWorkflowConvertor taskConvertor; + protected AbstractAlfredApiWorkflowConvertor taskConvertor; public String getId(T instance) { return ((WorkflowInstance) instance).getId(); @@ -62,8 +62,8 @@ private Workflow apply(WorkflowInstance instance, WorkflowTask startTask) { } else { Workflow ret = new Workflow(); ret.setId(instance.getId()); - Task startTaskApix = (Task) this.taskConvertor.apply(startTask); - Map props = startTaskApix.getProperties(); + Task startTaskAlfredApi = (Task) this.taskConvertor.apply(startTask); + Map props = startTaskAlfredApi.getProperties(); PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/bpm/1.0}active", instance.isActive()); PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/bpm/1.0}context", instance.getContext()); PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/bpm/1.0}description", instance.getDescription()); @@ -72,7 +72,7 @@ private Workflow apply(WorkflowInstance instance, WorkflowTask startTask) { PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/bpm/1.0}startDate", instance.getStartDate()); PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/bpm/1.0}id", ret.id); PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/bpm/1.0}initiator", - this.c.apix(instance.getInitiator())); + this.c.alfredApi(instance.getInitiator())); PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/content/1.0}name", instance.getDefinition().getName()); PutOnMapIfNotNull(props, "{http://www.alfresco.org/model/bpm/1.0}version", diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoWorkflowTaskWorkflowConvertor.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoWorkflowTaskWorkflowConvertor.java similarity index 92% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoWorkflowTaskWorkflowConvertor.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoWorkflowTaskWorkflowConvertor.java index f061a707..d12f8680 100644 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoWorkflowTaskWorkflowConvertor.java +++ b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/alfresco/AlfrescoWorkflowTaskWorkflowConvertor.java @@ -1,6 +1,6 @@ package eu.xenit.alfred.api.alfresco.workflow.alfresco; -import eu.xenit.alfred.api.alfresco.workflow.AbstractApixAlfrescoWorkflowConvertor; +import eu.xenit.alfred.api.alfresco.workflow.AbstractAlfredApiAlfrescoWorkflowConvertor; import eu.xenit.alfred.api.alfresco.workflow.activiti.ActivitiWorkflowTaskWorkflowConvertor; import eu.xenit.alfred.api.workflow.IWorkflowService; import eu.xenit.alfred.api.workflow.model.ITaskOrWorkflow; @@ -24,7 +24,7 @@ import org.springframework.stereotype.Component; @Component("eu.xenit.alfred.api.alfresco.workflow.alfresco.AlfrescoWorkflowTaskWorkflowConvertor") -public class AlfrescoWorkflowTaskWorkflowConvertor extends AbstractApixAlfrescoWorkflowConvertor { +public class AlfrescoWorkflowTaskWorkflowConvertor extends AbstractAlfredApiAlfrescoWorkflowConvertor { private static final Logger logger = LoggerFactory.getLogger(AlfrescoWorkflowTaskWorkflowConvertor.class); @@ -54,10 +54,10 @@ public Task apply(T obj) { WorkflowTaskDefinition tD = task.getDefinition(); ArrayList transitions = getTaskTransitions(task); TaskDefinition definition = new TaskDefinition(tD.getId(), tD.getMetadata().getProperties().keySet()); - Map props = toApixProperties(task.getProperties()); + Map props = toAlfredApiProperties(task.getProperties()); String workflowId = task.getPath().getInstance().getId(); - eu.xenit.alfred.api.data.NodeRef apixAssignee = null; + eu.xenit.alfred.api.data.NodeRef alfredApiAssignee = null; Serializable assigneeSerializable = task.getProperties().get(QNAME_ASSIGNEE); if (assigneeSerializable != null) { logger.debug( @@ -65,22 +65,22 @@ public Task apply(T obj) { + assigneeSerializable.toString()); if (assigneeSerializable instanceof String) { String assigneeName = (String) assigneeSerializable; - apixAssignee = this.getUserNodeRef(assigneeName); + alfredApiAssignee = this.getUserNodeRef(assigneeName); } else if (assigneeSerializable instanceof NodeRef) { NodeRef assigneeNodeRef = (NodeRef) assigneeSerializable; - apixAssignee = c.apix(assigneeNodeRef); + alfredApiAssignee = c.alfredApi(assigneeNodeRef); } } - eu.xenit.alfred.api.data.NodeRef apixGroupAssignee = null; + eu.xenit.alfred.api.data.NodeRef alfredApiGroupAssignee = null; Serializable groupNodeRef = task.getProperties().get(QNAME_GROUP_ASSIGNEE); if (groupNodeRef != null) { logger.debug( "eu.xenit.alfred.api.alfresco.workflow.alfresco.AlfrescoWorkflowTaskWorkflowConvertor.apply() groupNodeRef: " + groupNodeRef.toString()); NodeRef groupAssignee = (NodeRef) groupNodeRef; - apixGroupAssignee = this.c.apix(groupAssignee); + alfredApiGroupAssignee = this.c.alfredApi(groupAssignee); } String user = getCurrentUser(); @@ -89,7 +89,7 @@ public Task apply(T obj) { String description = getDescription(task); - PutOnMapIfNotNull(props, WorkflowModel.ASSOC_ASSIGNEE, apixAssignee); + PutOnMapIfNotNull(props, WorkflowModel.ASSOC_ASSIGNEE, alfredApiAssignee); PutOnMapIfNotNull(props, WorkflowModel.PROP_DESCRIPTION, description); PutOnMapIfNotNull(props, WorkflowModel.TYPE_TASK, task.getName()); PutOnMapIfNotNull(props, IWorkflowService.ALFRESCO_DEFINITION, definition); @@ -97,7 +97,7 @@ public Task apply(T obj) { PutOnMapIfNotNull(props, IWorkflowService.ALFRESCO_TITLE, task.getTitle()); PutOnMapIfNotNull(props, IWorkflowService.ALFRESCO_TRANSITIONS, transitions); PutOnMapIfNotNull(props, WorkflowModel.PROP_WORKFLOW_INSTANCE_ID, workflowId); - PutOnMapIfNotNull(props, IWorkflowService.ALFRESCO_GROUP_ASSIGNEE, apixGroupAssignee); + PutOnMapIfNotNull(props, IWorkflowService.ALFRESCO_GROUP_ASSIGNEE, alfredApiGroupAssignee); PutOnMapIfNotNull(props, IWorkflowService.ALFRESCO_CLAIMABLE, isTaskClaimable); PutOnMapIfNotNull(props, IWorkflowService.ALFRESCO_RELEASABLE, isTaskReleasable); ret.setProperties(props); diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsContainer.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsContainer.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsContainer.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsContainer.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormDefinition.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormDefinition.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormDefinition.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormDefinition.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormField.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormField.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormField.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/aps/ApsFormField.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/DebugHelper.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/DebugHelper.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/DebugHelper.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/DebugHelper.java diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/QueryStringFormatter.java b/alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/QueryStringFormatter.java similarity index 100% rename from apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/QueryStringFormatter.java rename to alfred-api-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/utils/QueryStringFormatter.java diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitorTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitorTest.java similarity index 100% rename from apix-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitorTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsFilterQueryNodeVisitorTest.java diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitorUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitorUnitTest.java similarity index 100% rename from apix-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitorUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/alfresco/search/FtsNodeVisitorUnitTest.java diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/dictionary/TypeServiceUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/dictionary/TypeServiceUnitTest.java similarity index 75% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/dictionary/TypeServiceUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/dictionary/TypeServiceUnitTest.java index dfcee871..117702eb 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/dictionary/TypeServiceUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/dictionary/TypeServiceUnitTest.java @@ -3,7 +3,7 @@ import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.alfresco.dictionary.TypeService; import eu.xenit.alfred.api.data.QName; import org.alfresco.service.cmr.dictionary.DictionaryService; @@ -22,9 +22,9 @@ public class TypeServiceUnitTest { public void testGetTypeDefinition_returnsNull_whenQnameInvalid() { QName invalidQname = new QName("someNamespace:someQname"); DictionaryService dictionaryServiceMock = mock(DictionaryService.class); - ApixToAlfrescoConversion apixToAlfrescoConversionMock = mock(ApixToAlfrescoConversion.class); - when(apixToAlfrescoConversionMock.alfresco(invalidQname)).thenThrow(NamespaceException.class); - TypeService typeService = new TypeService(dictionaryServiceMock, apixToAlfrescoConversionMock); + AlfredApiToAlfrescoConversion alfredApiToAlfrescoConversionMock = mock(AlfredApiToAlfrescoConversion.class); + when(alfredApiToAlfrescoConversionMock.alfresco(invalidQname)).thenThrow(NamespaceException.class); + TypeService typeService = new TypeService(dictionaryServiceMock, alfredApiToAlfrescoConversionMock); Assertions.assertNull(typeService.GetTypeDefinition(invalidQname), "[FAIL] An invalid qname did not result in a null response."); } diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsBaseUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsBaseUnitTest.java similarity index 88% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsBaseUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsBaseUnitTest.java index 17b7ad9b..80bd4458 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsBaseUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsBaseUnitTest.java @@ -4,7 +4,7 @@ import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import org.alfresco.service.ServiceRegistry; import org.alfresco.service.cmr.repository.NodeRef; import org.alfresco.service.cmr.repository.NodeService; @@ -15,7 +15,7 @@ public abstract class AncestorsBaseUnitTest { protected ServiceRegistry serviceRegistry; - protected ApixToAlfrescoConversion apixAlfrescoConverter; + protected AlfredApiToAlfrescoConversion alfredApiAlfrescoConverter; protected NodeRef testNode1 = new NodeRef("workspapce://SpacesStore/d1ef44c4-5bd3-457a-9b08-abd23d588bce"); protected NodeRef testNode2 = new NodeRef("workspapce://SpacesStore/d1ef44c4-5bd3-457a-9b08-abd23d588bcf"); @@ -30,8 +30,7 @@ public void init() { NodeService nodeServiceMock = initNodeServiceMock(); when(serviceRegistry.getNodeService()).thenReturn(nodeServiceMock); - //Initializing apixAlfrescoConverter - apixAlfrescoConverter = new ApixToAlfrescoConversion(serviceRegistry); + alfredApiAlfrescoConverter = new AlfredApiToAlfrescoConversion(serviceRegistry); } protected PermissionService initPermissionServiceMock() { diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromInaccessibleNodeUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromInaccessibleNodeUnitTest.java similarity index 89% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromInaccessibleNodeUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromInaccessibleNodeUnitTest.java index 5a82bb7f..54359161 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromInaccessibleNodeUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromInaccessibleNodeUnitTest.java @@ -46,11 +46,11 @@ protected PermissionService initPermissionServiceMock() { public void getAncestorsOfNodeTest() { Assertions.assertThrows(AccessDeniedException.class, ()->{ - eu.xenit.alfred.api.alfresco.metadata.NodeService apixNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( - serviceRegistry, apixAlfrescoConverter); + eu.xenit.alfred.api.alfresco.metadata.NodeService alfredApiNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( + serviceRegistry, alfredApiAlfrescoConverter); NodeRef rootRef = new NodeRef(testNode3.toString()); NodeRef testNode = new NodeRef(testNode1.toString()); - apixNodeService.getAncestors(testNode, rootRef); + alfredApiNodeService.getAncestors(testNode, rootRef); }, "Expected an AccessDeniedException to be thrown"); } } diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNodeUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNodeUnitTest.java similarity index 91% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNodeUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNodeUnitTest.java index 81e51094..6abf692d 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNodeUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNodeUnitTest.java @@ -41,11 +41,11 @@ public void getAncestorsOfNodeTest() { PermissionService alfrescoPermissionService = serviceRegistry.getPermissionService(); NodeService alfrescoNodeService = serviceRegistry.getNodeService(); - eu.xenit.alfred.api.alfresco.metadata.NodeService apixNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( - serviceRegistry, apixAlfrescoConverter); + eu.xenit.alfred.api.alfresco.metadata.NodeService alfredApiNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( + serviceRegistry, alfredApiAlfrescoConverter); NodeRef rootRef = new NodeRef(testNode3.toString()); NodeRef testNode = new NodeRef(testNode1.toString()); - List ancestors = apixNodeService.getAncestors(testNode, rootRef); + List ancestors = alfredApiNodeService.getAncestors(testNode, rootRef); Assertions.assertEquals(2, ancestors.size()); Assertions.assertEquals(testNode2.toString(), ancestors.get(0).toString()); Assertions.assertEquals(testNode3.toString(), ancestors.get(1).toString()); diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNonExistingNodeUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNonExistingNodeUnitTest.java similarity index 87% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNonExistingNodeUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNonExistingNodeUnitTest.java index 998f9ae1..98c9d605 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNonExistingNodeUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/AncestorsFromNonExistingNodeUnitTest.java @@ -35,12 +35,12 @@ protected NodeService initNodeServiceMock() { public void getAncestorsOfNodeTest() { Assertions.assertThrows(InvalidNodeRefException.class, ()->{ - eu.xenit.alfred.api.alfresco.metadata.NodeService apixNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( - serviceRegistry, apixAlfrescoConverter); + eu.xenit.alfred.api.alfresco.metadata.NodeService alfredApiNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( + serviceRegistry, alfredApiAlfrescoConverter); NodeRef rootRef = new NodeRef(testNode3.toString()); NodeRef testNode = new NodeRef(testNode1.toString()); - apixNodeService.getAncestors(testNode, rootRef); + alfredApiNodeService.getAncestors(testNode, rootRef); }, "Expected an InvalidNodeRefException to be thrown"); } } diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/RenameUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/RenameUnitTest.java similarity index 89% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/RenameUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/RenameUnitTest.java index 1ae2ef5f..e8129e0e 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/RenameUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/RenameUnitTest.java @@ -7,7 +7,7 @@ import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.data.NodeRef; import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.node.MetadataChanges; @@ -27,7 +27,7 @@ public class RenameUnitTest { private ServiceRegistry serviceRegistry; - private ApixToAlfrescoConversion apixAlfrescoConverter; + private AlfredApiToAlfrescoConversion alfredApiAlfrescoConverter; private static final String NODEREF_STRING = "workspapce://SpacesStore/d1ef44c4-5bd3-457a-9b08-abd23d588bce"; private static final String NEW_NAME = "newName"; @@ -58,7 +58,7 @@ public void init() { when(serviceRegistry.getDictionaryService()).thenReturn(dictionaryServiceMock); //Initializing Alfred API to Alfresco converter - apixAlfrescoConverter = new ApixToAlfrescoConversion(serviceRegistry); + alfredApiAlfrescoConverter = new AlfredApiToAlfrescoConversion(serviceRegistry); } @Test @@ -77,9 +77,9 @@ public void testSetNameCallsRenameOfFileFolderService() { propertiesToSet.put(nameProperty, namePropertyValue); MetadataChanges metadataChanges = new MetadataChanges(null, aspectsToAdd, aspectsToRemove, propertiesToSet); - eu.xenit.alfred.api.alfresco.metadata.NodeService apixNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( - serviceRegistry, apixAlfrescoConverter); - apixNodeService.setMetadata(nodeRef, metadataChanges); + eu.xenit.alfred.api.alfresco.metadata.NodeService alfredApiNodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService( + serviceRegistry, alfredApiAlfrescoConverter); + alfredApiNodeService.setMetadata(nodeRef, metadataChanges); //We have to make sure that the rename method of the file folder service was called once. //That way we know that the qname path was also changed. diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/SetMetadataUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/SetMetadataUnitTest.java similarity index 89% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/SetMetadataUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/SetMetadataUnitTest.java index 975ef6c4..be366c5c 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/SetMetadataUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/metadata/SetMetadataUnitTest.java @@ -11,7 +11,7 @@ import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.node.MetadataChanges; import java.util.ArrayList; import java.util.HashMap; @@ -46,15 +46,15 @@ public class SetMetadataUnitTest { private NodeRef testNodeRef = new NodeRef("workspace://SpacesStore/00000000-0000-0000-0000-000000000000"); private eu.xenit.alfred.api.alfresco.metadata.NodeService nodeService; - private ApixToAlfrescoConversion apixAlfrescoConverter; + private AlfredApiToAlfrescoConversion alfredApiAlfrescoConverter; private ServiceRegistry serviceRegistryMock; private NodeService nodeServiceAlfrescoMock; @BeforeEach public void init() { - //Initialization of serviceRegistry and apixAlfrescoConverter + //Initialization of serviceRegistry and alfredApiAlfrescoConverter serviceRegistryMock = mock(ServiceRegistry.class); - apixAlfrescoConverter = new ApixToAlfrescoConversion(serviceRegistryMock); + alfredApiAlfrescoConverter = new AlfredApiToAlfrescoConversion(serviceRegistryMock); //Creating Alfresco NodeService mock nodeServiceAlfrescoMock = initNodeServiceMock(); @@ -65,7 +65,8 @@ public void init() { when(serviceRegistryMock.getDictionaryService()).thenReturn(dictionaryServiceMock); //Initialization of nodeService - nodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService(serviceRegistryMock, apixAlfrescoConverter); + nodeService = new eu.xenit.alfred.api.alfresco.metadata.NodeService(serviceRegistryMock, + alfredApiAlfrescoConverter); } private NodeService initNodeServiceMock() { @@ -206,14 +207,14 @@ public void testGeneralizeTypeWithCleanUpEnabled() { Set targetTypeSet = new HashSet<>(); targetTypeSet.add(targetType); - MetadataChanges changes = new MetadataChanges(apixAlfrescoConverter.apixQNames(targetTypeSet).iterator().next() + MetadataChanges changes = new MetadataChanges(alfredApiAlfrescoConverter.alfredApiQNames(targetTypeSet).iterator().next() , true, null, null, null); Set testNodeRefSet = new HashSet<>(); testNodeRefSet.add(testNodeRef); - eu.xenit.alfred.api.data.NodeRef apixTestNodeRef = apixAlfrescoConverter.apixNodeRefs(testNodeRefSet).iterator() + eu.xenit.alfred.api.data.NodeRef alfredApiTestNodeRef = alfredApiAlfrescoConverter.alfredApiNodeRefs(testNodeRefSet).iterator() .next(); eu.xenit.alfred.api.alfresco.metadata.NodeService nodeServiceSpy = spy(nodeService); - nodeServiceSpy.setMetadata(apixTestNodeRef, changes); + nodeServiceSpy.setMetadata(alfredApiTestNodeRef, changes); verify(nodeServiceAlfrescoMock).setType(eq(testNodeRef), eq(targetType)); verify(nodeServiceSpy).cleanupAspects(any(), any(), any()); verify(nodeServiceAlfrescoMock, times(0)) @@ -231,13 +232,13 @@ public void testGeneralizeTypeWithCleanUpEnabledAndAdditionalAspects() { targetTypeSet.add(targetType); eu.xenit.alfred.api.data.QName[] aspectsToAdd = new eu.xenit.alfred.api.data.QName[1]; aspectsToAdd[0] = new eu.xenit.alfred.api.data.QName(ASPECT4); - MetadataChanges changes = new MetadataChanges(apixAlfrescoConverter.apixQNames(targetTypeSet).iterator().next() + MetadataChanges changes = new MetadataChanges(alfredApiAlfrescoConverter.alfredApiQNames(targetTypeSet).iterator().next() , true, aspectsToAdd, null, null); Set testNodeRefSet = new HashSet<>(); testNodeRefSet.add(testNodeRef); - eu.xenit.alfred.api.data.NodeRef apixTestNodeRef = apixAlfrescoConverter.apixNodeRefs(testNodeRefSet).iterator() + eu.xenit.alfred.api.data.NodeRef alfredApiTestNodeRef = alfredApiAlfrescoConverter.alfredApiNodeRefs(testNodeRefSet).iterator() .next(); - nodeService.setMetadata(apixTestNodeRef, changes); + nodeService.setMetadata(alfredApiTestNodeRef, changes); verify(nodeServiceAlfrescoMock).setType(eq(testNodeRef), eq(targetType)); verify(nodeServiceAlfrescoMock).removeAspect(eq(testNodeRef), eq(QName.createQName(ASPECT3))); @@ -255,13 +256,13 @@ public void testGeneralizeTypeWithCleanUpEnabledAndAddingAspectToBeCleanedUp() { targetTypeSet.add(targetType); eu.xenit.alfred.api.data.QName[] aspectsToAdd = new eu.xenit.alfred.api.data.QName[1]; aspectsToAdd[0] = new eu.xenit.alfred.api.data.QName(ASPECT3); - MetadataChanges changes = new MetadataChanges(apixAlfrescoConverter.apixQNames(targetTypeSet).iterator().next() + MetadataChanges changes = new MetadataChanges(alfredApiAlfrescoConverter.alfredApiQNames(targetTypeSet).iterator().next() , true, aspectsToAdd, null, null); Set testNodeRefSet = new HashSet<>(); testNodeRefSet.add(testNodeRef); - eu.xenit.alfred.api.data.NodeRef apixTestNodeRef = apixAlfrescoConverter.apixNodeRefs(testNodeRefSet).iterator() + eu.xenit.alfred.api.data.NodeRef alfredApiTestNodeRef = alfredApiAlfrescoConverter.alfredApiNodeRefs(testNodeRefSet).iterator() .next(); - nodeService.setMetadata(apixTestNodeRef, changes); + nodeService.setMetadata(alfredApiTestNodeRef, changes); InOrder inOrder = inOrder(nodeServiceAlfrescoMock); inOrder.verify(nodeServiceAlfrescoMock).setType(eq(testNodeRef), eq(targetType)); @@ -277,14 +278,14 @@ public void testGeneralizeTypeWithCleanUpDisabled() { QName targetType = initialTypeDef.getParentName(); Set targetTypeSet = new HashSet<>(); targetTypeSet.add(targetType); - MetadataChanges changes = new MetadataChanges(apixAlfrescoConverter.apixQNames(targetTypeSet).iterator().next() + MetadataChanges changes = new MetadataChanges(alfredApiAlfrescoConverter.alfredApiQNames(targetTypeSet).iterator().next() , false, null, null, null); Set testNodeRefSet = new HashSet<>(); testNodeRefSet.add(testNodeRef); - eu.xenit.alfred.api.data.NodeRef apixTestNodeRef = apixAlfrescoConverter.apixNodeRefs(testNodeRefSet).iterator() + eu.xenit.alfred.api.data.NodeRef alfredApiTestNodeRef = alfredApiAlfrescoConverter.alfredApiNodeRefs(testNodeRefSet).iterator() .next(); eu.xenit.alfred.api.alfresco.metadata.NodeService nodeServiceSpy = spy(nodeService); - nodeServiceSpy.setMetadata(apixTestNodeRef, changes); + nodeServiceSpy.setMetadata(alfredApiTestNodeRef, changes); verify(nodeServiceAlfrescoMock).setType(eq(testNodeRef), eq(targetType)); verify(nodeServiceSpy, times(0)).cleanupAspects(any(), any(), any()); verify(nodeServiceAlfrescoMock, times(0)) diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java similarity index 97% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java index c35ce7b9..9110d414 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java @@ -83,10 +83,10 @@ public void testExistsTerm() { assertEquals("EXISTS:\"prefix:test_prop\"", convertToFtsTerm(EXISTS)); } - private String convertToFtsTerm(String apixTerm) { + private String convertToFtsTerm(String alfredApiTerm) { PropertyService propertyService = new PropertyServiceStub(propertyToDataType); FtsNodeVisitor ftsnodeVisitor = new FtsNodeVisitor(propertyService); - TermSearchNode searchNode = new TermSearchNode(apixTerm, "prefix:test_prop"); + TermSearchNode searchNode = new TermSearchNode(alfredApiTerm, "prefix:test_prop"); return ftsnodeVisitor.visit(searchNode); } diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchFacetServiceUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchFacetServiceUnitTest.java similarity index 93% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchFacetServiceUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchFacetServiceUnitTest.java index 871aa409..7b6e6ab5 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchFacetServiceUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchFacetServiceUnitTest.java @@ -66,7 +66,7 @@ public void initMocks() { DictionaryService dictionaryServiceMock = mock(DictionaryService.class); - QName languageQName = QName.createQName("{http://test.apix.xenit.eu/model/content}language"); + QName languageQName = QName.createQName("{http://test.alfredapi.xenit.eu/model/content}language"); PropertyDefinition languagePropDefMock = mock(PropertyDefinition.class); List languageConstraintDefinitions = new ArrayList<>(); ConstraintDefinition theLanguageConstraintDefinition = mock(ConstraintDefinition.class); @@ -75,7 +75,7 @@ public void initMocks() { listOfValues.add("Dutch"); theListOfValuesConstraint.setAllowedValues(listOfValues); theListOfValuesConstraint - .setShortName("{http://test.apix.xenit.eu/model/content}model_hasLanguage_language_anon_0"); + .setShortName("{http://test.alfredapi.xenit.eu/model/content}model_hasLanguage_language_anon_0"); when(theListOfValuesConstraint.getDisplayLabel(eq("Dutch"), any(MessageLookup.class))).thenReturn("Nederlands"); when(theLanguageConstraintDefinition.getConstraint()).thenReturn(theListOfValuesConstraint); languageConstraintDefinitions.add(theLanguageConstraintDefinition); @@ -83,7 +83,7 @@ public void initMocks() { when(languagePropDefMock.getDataType()).thenReturn(textDataTypeDef); when(dictionaryServiceMock.getProperty(languageQName)).thenReturn(languagePropDefMock); - QName documentStatusQName = QName.createQName("{http://test.apix.xenit.eu/model/content}documentStatus"); + QName documentStatusQName = QName.createQName("{http://test.alfredapi.xenit.eu/model/content}documentStatus"); PropertyDefinition documentStatusPropDefMock = mock(PropertyDefinition.class); List documnetStatusConDefList = new ArrayList<>(); ConstraintDefinition documentStatusConDef = mock(ConstraintDefinition.class); @@ -92,7 +92,7 @@ public void initMocks() { docStatLOV.add("Draft"); docStatLOVConstr.setAllowedValues(docStatLOV); docStatLOVConstr.setShortName( - "{http://test.apix.xenit.eu/model/content}model_withMandatoryPropDocument_documentStatus_anon_0"); + "{http://test.alfredapi.xenit.eu/model/content}model_withMandatoryPropDocument_documentStatus_anon_0"); when(docStatLOVConstr.getDisplayLabel(eq("Draft"), any(MessageLookup.class))).thenReturn("Draft"); when(documentStatusConDef.getConstraint()).thenReturn(docStatLOVConstr); documnetStatusConDefList.add(documentStatusConDef); @@ -115,9 +115,9 @@ public void initMocks() { Pair documentStatusFieldFacetResult = new Pair("Draft", 1); languageFieldFacetResults.add(languageFieldFacetResult); documentStatusFieldFacetResults.add(documentStatusFieldFacetResult); - when(resultSetMock.getFieldFacet("@{http://test.apix.xenit.eu/model/content}language")) + when(resultSetMock.getFieldFacet("@{http://test.alfredapi.xenit.eu/model/content}language")) .thenReturn(languageFieldFacetResults); - when(resultSetMock.getFieldFacet("@{http://test.apix.xenit.eu/model/content}documentStatus")) + when(resultSetMock.getFieldFacet("@{http://test.alfredapi.xenit.eu/model/content}documentStatus")) .thenReturn(documentStatusFieldFacetResults); Map facetQueries = new HashMap<>(); facetQueries.put("{!afts}@{http://www.alfresco.org/model/content/1.0}content.size:[0 TO 10240]", 1); @@ -128,10 +128,10 @@ public void initMocks() { searchParametersMock = mock(SearchParameters.class); List fieldFacets = new ArrayList<>(); FieldFacet fieldFacetMock_A = mock(FieldFacet.class); - when(fieldFacetMock_A.getField()).thenReturn("@{http://test.apix.xenit.eu/model/content}language"); + when(fieldFacetMock_A.getField()).thenReturn("@{http://test.alfredapi.xenit.eu/model/content}language"); fieldFacets.add(fieldFacetMock_A); FieldFacet fieldFacetMock_B = mock(FieldFacet.class); - when(fieldFacetMock_B.getField()).thenReturn("@{http://test.apix.xenit.eu/model/content}documentStatus"); + when(fieldFacetMock_B.getField()).thenReturn("@{http://test.alfredapi.xenit.eu/model/content}documentStatus"); fieldFacets.add(fieldFacetMock_B); when(searchParametersMock.getFieldFacets()).thenReturn(fieldFacets); when(translationServiceMock.getMessageTranslation("faceted-search.size.0-10KB.label")).thenReturn("0 to 10KB"); @@ -174,7 +174,7 @@ private FacetLabelDisplayHandlerRegistry initFacetLabelDisplayHandler(ServiceReg public List initExpectedResult_for_assertThat_getFacetResults_returnIncludes_translationsForListOfValueConstraints() { List expectedResult = new ArrayList<>(); FacetSearchResult languageResult = new FacetSearchResult(); - languageResult.setName("{http://test.apix.xenit.eu/model/content}language"); + languageResult.setName("{http://test.alfredapi.xenit.eu/model/content}language"); List languageFacetValues = new ArrayList<>(); FacetValue dutchFacetValue = new FacetValue(); dutchFacetValue.setValue("Dutch"); @@ -184,7 +184,7 @@ public List initExpectedResult_for_assertThat_getFacetResults languageResult.setValues(languageFacetValues); expectedResult.add(languageResult); FacetSearchResult documentStatusResult = new FacetSearchResult(); - documentStatusResult.setName("{http://test.apix.xenit.eu/model/content}documentStatus"); + documentStatusResult.setName("{http://test.alfredapi.xenit.eu/model/content}documentStatus"); List documentStatusValues = new ArrayList<>(); FacetValue draftFacetValue = new FacetValue(); draftFacetValue.setValue("Draft"); diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchServiceUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchServiceUnitTest.java similarity index 84% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchServiceUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchServiceUnitTest.java index 5c423ebb..b237e551 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchServiceUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/search/SearchServiceUnitTest.java @@ -5,7 +5,7 @@ import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.alfresco.dictionary.PropertyService; import eu.xenit.alfred.api.alfresco.search.SearchFacetsService; import eu.xenit.alfred.api.alfresco.search.SearchResultCountService; @@ -61,7 +61,7 @@ public void testDefaultSearchQueryConsistencyIsTransactionalIfPossible() { @Test public void testSearchQueryConsistencyIsSetToEventualIfFacetsIsEnabled() { org.alfresco.service.cmr.search.SearchService alfrescoSearchServiceMock = buildAlfrescoSearchServiceMock(); - SearchService apixSearchServiceMocked = buildApixSearchServiceWithMocks( + SearchService alfredApiSearchServiceMocked = buildAlfredApiSearchServiceWithMocks( StoreRef.STORE_REF_WORKSPACE_SPACESSTORE, alfrescoSearchServiceMock); SearchQuery searchQuery = new SearchQuery(); @@ -82,13 +82,13 @@ public void testSearchQueryConsistencyIsSetToEventualIfFacetsIsEnabled() { searchQuery.setQuery(node); //Setting workspace - eu.xenit.alfred.api.data.StoreRef apixStore = new eu.xenit.alfred.api.data.StoreRef( + eu.xenit.alfred.api.data.StoreRef alfredApiStore = new eu.xenit.alfred.api.data.StoreRef( StoreRef.STORE_REF_WORKSPACE_SPACESSTORE.toString()); - searchQuery.setWorkspace(apixStore); + searchQuery.setWorkspace(alfredApiStore); //Executing query and checking query consistency given to Alfresco search service ArgumentCaptor searchParamsArgument = ArgumentCaptor.forClass(SearchParameters.class); - apixSearchServiceMocked.query(searchQuery); + alfredApiSearchServiceMocked.query(searchQuery); verify(alfrescoSearchServiceMock).query(searchParamsArgument.capture()); Assertions.assertEquals(QueryConsistency.EVENTUAL, searchParamsArgument.getValue().getQueryConsistency()); } @@ -97,7 +97,7 @@ public void testSearchQueryConsistencyIsSetToEventualIfFacetsIsEnabled() { public void testOrderBy_withMultivalueProperty_throwsIllegalArgumentException() { Assertions.assertThrows(IllegalArgumentException.class, ()->{ - SearchService apixSearchServiceMocked = buildApixSearchServiceWithMocks( + SearchService alfredApiSearchServiceMocked = buildAlfredApiSearchServiceWithMocks( StoreRef.STORE_REF_WORKSPACE_SPACESSTORE); PropertyService propertyServiceMock_withMultivalueTrue = mock(PropertyService.class); @@ -105,7 +105,7 @@ public void testOrderBy_withMultivalueProperty_throwsIllegalArgumentException() when(propertyDefinition.isMultiValued()).thenReturn(true); when(propertyServiceMock_withMultivalueTrue.GetPropertyDefinition(any(QName.class))) .thenReturn(propertyDefinition); - apixSearchServiceMocked.setPropertyService(propertyServiceMock_withMultivalueTrue); + alfredApiSearchServiceMocked.setPropertyService(propertyServiceMock_withMultivalueTrue); QueryBuilder builder = new QueryBuilder(); SearchSyntaxNode node = builder @@ -113,21 +113,21 @@ public void testOrderBy_withMultivalueProperty_throwsIllegalArgumentException() .create(); SearchQuery query = new SearchQuery(); query.setQuery(node); - eu.xenit.alfred.api.data.StoreRef apixStore = new eu.xenit.alfred.api.data.StoreRef( + eu.xenit.alfred.api.data.StoreRef alfredApiStore = new eu.xenit.alfred.api.data.StoreRef( StoreRef.STORE_REF_WORKSPACE_SPACESSTORE.toString()); - query.setWorkspace(apixStore); - QName apixQname = new QName("cm:multivalued"); - OrderBy multivalueOrdering = new OrderBy(Order.ASCENDING, apixQname); + query.setWorkspace(alfredApiStore); + QName alfredApiQname = new QName("cm:multivalued"); + OrderBy multivalueOrdering = new OrderBy(Order.ASCENDING, alfredApiQname); ArrayList orderings = new ArrayList<>(); orderings.add(multivalueOrdering); query.setOrderBy(orderings); - apixSearchServiceMocked.query(query); + alfredApiSearchServiceMocked.query(query); }, "Expected an IllegalArgumentException to be thrown by testOrderBy_withMultivalueProperty_throwsIllegalArgumentException"); } @Test public void testLimitDefault() { - SearchService searchService = buildApixSearchServiceWithMocks(null); + SearchService searchService = buildAlfredApiSearchServiceWithMocks(null); SearchQuery query = new SearchQuery(); query.setQuery(new QueryBuilder().property("foo", "bar").create()); @@ -137,7 +137,7 @@ public void testLimitDefault() { @Test public void testLimit() { - SearchService searchService = buildApixSearchServiceWithMocks(null); + SearchService searchService = buildAlfredApiSearchServiceWithMocks(null); SearchQuery query = new SearchQuery(); query.setQuery(new QueryBuilder().property("foo", "bar").create()); @@ -173,28 +173,28 @@ private org.alfresco.service.cmr.search.SearchService searchInStore(StoreRef sto // // Set the test StoreRef - eu.xenit.alfred.api.data.StoreRef apixStore = null; + eu.xenit.alfred.api.data.StoreRef alfredApiStore = null; String storeString = ""; if (store != null) { storeString = store.toString(); - apixStore = new eu.xenit.alfred.api.data.StoreRef(storeString); + alfredApiStore = new eu.xenit.alfred.api.data.StoreRef(storeString); } - query.setWorkspace(apixStore); + query.setWorkspace(alfredApiStore); // Execute the action - SearchService apixSearchService = buildApixSearchServiceWithMocks(store); - apixSearchService.query(query); + SearchService alfredApiSearchService = buildAlfredApiSearchServiceWithMocks(store); + alfredApiSearchService.query(query); - return apixSearchService.getSearchService(); + return alfredApiSearchService.getSearchService(); } - private SearchService buildApixSearchServiceWithMocks(StoreRef store, + private SearchService buildAlfredApiSearchServiceWithMocks(StoreRef store, org.alfresco.service.cmr.search.SearchService alfrescoSearchServiceMock) { ServiceRegistry serviceRegistry = mock(ServiceRegistry.class); when(serviceRegistry.getSearchService()) .thenReturn(alfrescoSearchServiceMock); - ApixToAlfrescoConversion c = mock(ApixToAlfrescoConversion.class); + AlfredApiToAlfrescoConversion c = mock(AlfredApiToAlfrescoConversion.class); String storeString = ""; if (store != null) { storeString = store.toString(); @@ -220,10 +220,10 @@ private SearchService buildApixSearchServiceWithMocks(StoreRef store, return new SearchService(serviceRegistry.getSearchService(), facetService, c, propertyService); } - private SearchService buildApixSearchServiceWithMocks(StoreRef store) { + private SearchService buildAlfredApiSearchServiceWithMocks(StoreRef store) { // Setup of the mock for Alfresco Search Service to verify the query parameters org.alfresco.service.cmr.search.SearchService alfrescoSearchService = buildAlfrescoSearchServiceMock(); - return buildApixSearchServiceWithMocks(store, alfrescoSearchService); + return buildAlfredApiSearchServiceWithMocks(store, alfrescoSearchService); } private org.alfresco.service.cmr.search.SearchService buildAlfrescoSearchServiceMock() { diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/sites/GetUserSitesUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/sites/GetUserSitesUnitTest.java similarity index 93% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/sites/GetUserSitesUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/sites/GetUserSitesUnitTest.java index 5a619bba..90547b9f 100644 --- a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/sites/GetUserSitesUnitTest.java +++ b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/sites/GetUserSitesUnitTest.java @@ -6,7 +6,7 @@ import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.sites.ISite; import java.util.ArrayList; import java.util.List; @@ -25,7 +25,7 @@ public class GetUserSitesUnitTest { private ServiceRegistry serviceRegistry; - private ApixToAlfrescoConversion apixAlfrescoConverter; + private AlfredApiToAlfrescoConversion alfredApiAlfrescoConverter; private SiteInfo testSite1; private SiteInfo testSite2; private SiteInfo testSite3; @@ -49,7 +49,7 @@ private void init() { SiteService siteServiceMock = initSiteServiceMock(); when(serviceRegistry.getSiteService()).thenReturn(siteServiceMock); - apixAlfrescoConverter = new ApixToAlfrescoConversion(serviceRegistry); + alfredApiAlfrescoConverter = new AlfredApiToAlfrescoConversion(serviceRegistry); } public void initWithInaccessibleComponent() { @@ -57,7 +57,7 @@ public void initWithInaccessibleComponent() { SiteService siteServiceMock = initSiteServiceWithInaccessibleComponent(); when(serviceRegistry.getSiteService()).thenReturn(siteServiceMock); - apixAlfrescoConverter = new ApixToAlfrescoConversion(serviceRegistry); + alfredApiAlfrescoConverter = new AlfredApiToAlfrescoConversion(serviceRegistry); } private SiteService initSiteServiceMock() { @@ -163,11 +163,11 @@ private void initSiteComponentsWithInaccessibleComponent(SiteService siteService public void testGetUserSites() { init(); SiteService alfrescoSiteService = serviceRegistry.getSiteService(); - eu.xenit.alfred.api.alfresco.sites.SiteService apixSiteService = - new eu.xenit.alfred.api.alfresco.sites.SiteService(serviceRegistry, apixAlfrescoConverter); + eu.xenit.alfred.api.alfresco.sites.SiteService alfredApiSiteService = + new eu.xenit.alfred.api.alfresco.sites.SiteService(serviceRegistry, alfredApiAlfrescoConverter); String user = "testUser"; - List testUserSites = apixSiteService.getUserSites(user); + List testUserSites = alfredApiSiteService.getUserSites(user); Assertions.assertNotEquals(null, testSite1); Assertions.assertNotEquals(null, testSite2); Assertions.assertNotEquals(null, testSite3); @@ -184,11 +184,11 @@ public void testGetUserSites() { @Test public void testGetUserSitesWithInaccessibleComponent() { initWithInaccessibleComponent(); - eu.xenit.alfred.api.alfresco.sites.SiteService apixSiteService = - new eu.xenit.alfred.api.alfresco.sites.SiteService(serviceRegistry, apixAlfrescoConverter); + eu.xenit.alfred.api.alfresco.sites.SiteService alfredApiSiteService = + new eu.xenit.alfred.api.alfresco.sites.SiteService(serviceRegistry, alfredApiAlfrescoConverter); String user = "testUser"; - List testUserSites = apixSiteService.getUserSites(user); + List testUserSites = alfredApiSiteService.getUserSites(user); Assertions.assertNotEquals(null, testSite1); Assertions.assertEquals(1, testUserSites.size()); Assertions.assertEquals(testSite1.getShortName(), testUserSites.get(0).getShortName()); diff --git a/apix-impl/src/test/java/eu/xenit/alfred/api/tests/translations/TranslationsServiceUnitTest.java b/alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/translations/TranslationsServiceUnitTest.java similarity index 100% rename from apix-impl/src/test/java/eu/xenit/alfred/api/tests/translations/TranslationsServiceUnitTest.java rename to alfred-api-impl/src/test/java/eu/xenit/alfred/api/tests/translations/TranslationsServiceUnitTest.java diff --git a/apix-impl/src/test/properties/local/alfresco-global.properties b/alfred-api-impl/src/test/properties/local/alfresco-global.properties similarity index 100% rename from apix-impl/src/test/properties/local/alfresco-global.properties rename to alfred-api-impl/src/test/properties/local/alfresco-global.properties diff --git a/apix-impl/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker b/alfred-api-impl/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker similarity index 100% rename from apix-impl/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker rename to alfred-api-impl/src/test/resources/mockito-extensions/org.mockito.plugins.MockMaker diff --git a/apix-integrationtests-client/alfresco/231/.gitkeep b/alfred-api-integrationtests-client/alfresco/231/.gitkeep similarity index 100% rename from apix-integrationtests-client/alfresco/231/.gitkeep rename to alfred-api-integrationtests-client/alfresco/231/.gitkeep diff --git a/apix-integrationtests-client/alfresco/232/.gitkeep b/alfred-api-integrationtests-client/alfresco/232/.gitkeep similarity index 100% rename from apix-integrationtests-client/alfresco/232/.gitkeep rename to alfred-api-integrationtests-client/alfresco/232/.gitkeep diff --git a/apix-integrationtests-client/alfresco/build.gradle b/alfred-api-integrationtests-client/alfresco/build.gradle similarity index 78% rename from apix-integrationtests-client/alfresco/build.gradle rename to alfred-api-integrationtests-client/alfresco/build.gradle index 1ebc59e3..d8664d36 100644 --- a/apix-integrationtests-client/alfresco/build.gradle +++ b/alfred-api-integrationtests-client/alfresco/build.gradle @@ -38,9 +38,9 @@ allprojects { check.dependsOn integrationTest dependencies { - alfrescoProvided(project(":apix-rest")) { transitive = false } - alfrescoProvided(project(":apix-interface")) { transitive = false } - alfrescoProvided(project(":apix-interface")) { transitive = false } + alfrescoProvided(project(":alfred-api-rest")) { transitive = false } + alfrescoProvided(project(":alfred-api-interface")) { transitive = false } + alfrescoProvided(project(":alfred-api-interface")) { transitive = false } alfrescoProvided platform("org.alfresco:acs-community-packaging:${alfresco_version}") alfrescoProvided("org.alfresco:alfresco-repository") @@ -52,25 +52,25 @@ allprojects { exclude group: 'org.apache.httpcomponents', module: 'httpcore' } // Add services used to the integration test fatjar, since we can't access the ones deployed in Alfresco - testImplementation(project(":apix-impl:apix-impl-${subproject_alfresco_version}")) + testImplementation(project(":alfred-api-impl:alfred-api-impl-${subproject_alfresco_version}")) // Read in the integration-test-server static ApplicationContext + Helperclasses - implementation project(path: ":apix-integrationtests-server") + implementation project(path: ":alfred-api-integrationtests-server") } } subprojects { // Subproject of supported Alfresco versions - def projectApixImpl = project(":apix-impl:apix-impl-${project.projectDir.name}") - def projectDocker = project(":apix-docker:docker-${project.projectDir.name}") - evaluationDependsOn(projectApixImpl.path) + def projectAlfredApiImpl = project(":alfred-api-impl:alfred-api-impl-${project.projectDir.name}") + def projectDocker = project(":alfred-api-docker:docker-${project.projectDir.name}") + evaluationDependsOn(projectAlfredApiImpl.path) evaluationDependsOn(projectDocker.path) - def assembleTask = projectApixImpl.tasks.getByName("assemble") + def assembleTask = projectAlfredApiImpl.tasks.getByName("assemble") def composeUpTask = projectDocker.tasks.getByName("composeUp") def composeDownTask = projectDocker.tasks.getByName("composeDown") // Only the integration tests actually need the Docker containers to run. However, they're currently part of the regular test suite. integrationTest { - // All defined in apix-docker build. Model-amp is installed. + // All defined in alfred-api-docker build. Model-amp is installed. dependsOn assembleTask dependsOn composeUpTask finalizedBy composeDownTask diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/BaseApplicationContextTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/BaseApplicationContextTest.java similarity index 92% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/BaseApplicationContextTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/BaseApplicationContextTest.java index 5df8b47c..68a2649c 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/BaseApplicationContextTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/BaseApplicationContextTest.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api; import com.github.ruediste.remoteJUnit.client.RemoteTestRunner; -import eu.xenit.alfred.api.alfresco.ApixToAlfrescoConversion; +import eu.xenit.alfred.api.alfresco.AlfredApiToAlfrescoConversion; import eu.xenit.alfred.api.server.Server; import org.alfresco.repo.admin.SysAdminParams; import org.alfresco.repo.model.Repository; @@ -20,7 +20,7 @@ public abstract class BaseApplicationContextTest { private final static Logger logger = LoggerFactory.getLogger(BaseApplicationContextTest.class); protected ServiceRegistry serviceRegistry; - protected ApixToAlfrescoConversion c; + protected AlfredApiToAlfrescoConversion c; protected Repository repository; protected ApplicationContext testApplicationContext; protected AuthenticationService authenticationService; @@ -32,7 +32,7 @@ public BaseApplicationContextTest() { // initialise the static application-context testApplicationContext = Server.getApplicationContext(); serviceRegistry = getBean(ServiceRegistry.class); - c = getBean(ApixToAlfrescoConversion.class); + c = getBean(AlfredApiToAlfrescoConversion.class); repository = getBean(Repository.class); transactionService = getBean(TransactionService.class); transactionHelper = getBean("retryingTransactionHelper", RetryingTransactionHelper.class); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/StagingBaseTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/StagingBaseTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/StagingBaseTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/StagingBaseTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/WorkflowTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/WorkflowTest.java similarity index 98% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/WorkflowTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/WorkflowTest.java index 2205e61f..261be402 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/WorkflowTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/staging/tests/WorkflowTest.java @@ -114,7 +114,7 @@ public void testClaimWorkflow() throws IOException { logger.debug("claimable: " + claimable); assertTrue(claimable); - String url = createApixUrl("/tasks/claim"); + String url = createAlfredApiUrl("/tasks/claim"); logger.debug(" URL: " + url); CloseableHttpClient httpclient = HttpClients.createDefault(); @@ -156,7 +156,7 @@ public Object execute() throws Throwable { logger.debug("releasable: " + releasable); assertTrue(releasable); - String url = createApixUrl("/tasks/release"); + String url = createAlfredApiUrl("/tasks/release"); logger.debug(" URL: " + url); CloseableHttpClient httpclient = HttpClients.createDefault(); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AllNodeInfoTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AllNodeInfoTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AllNodeInfoTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AllNodeInfoTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AssociationsTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AssociationsTest.java similarity index 93% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AssociationsTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AssociationsTest.java index 5c006e08..0cc65de2 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AssociationsTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/AssociationsTest.java @@ -100,20 +100,20 @@ public void testCreateAssociation() throws IOException { HashMap initializedNodeRefs = init(); final NodeRef nodeRefA = initializedNodeRefs.get(RestV1BaseTest.TESTFILE_NAME); final NodeRef nodeRefB = initializedNodeRefs.get(RestV1BaseTest.TESTFILE2_NAME); - org.alfresco.service.cmr.repository.NodeRef nodeRefApix = c.alfresco(nodeRefA); - logger.debug("nodeRefA {} , c.alfresco(nodeRefA)={}", nodeRefA, nodeRefApix); + org.alfresco.service.cmr.repository.NodeRef nodeRefAlfredApi = c.alfresco(nodeRefA); + logger.debug("nodeRefA {} , c.alfresco(nodeRefA)={}", nodeRefA, nodeRefAlfredApi); final java.util.List assocs = nodeService.getTargetAssocs( - nodeRefApix, RegexQNamePattern.MATCH_ALL); + nodeRefAlfredApi, RegexQNamePattern.MATCH_ALL); assertEquals(0, assocs.size()); doPost( - createApixUrl("/nodes/%s/%s/%s/associations", nodeRefA.getStoreRefProtocol(), nodeRefA.getStoreRefId(), + createAlfredApiUrl("/nodes/%s/%s/%s/associations", nodeRefA.getStoreRefProtocol(), nodeRefA.getStoreRefId(), nodeRefA.getGuid()), null, "{'target':'%s','type':'%s'}", - nodeRefB, c.apix(ContentModel.ASSOC_ORIGINAL)); + nodeRefB, c.alfredApi(ContentModel.ASSOC_ORIGINAL)); serviceRegistry.getRetryingTransactionHelper() .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @@ -154,9 +154,9 @@ public Object execute() throws Throwable { }, false, true); doDelete( - createApixUrl("/nodes/%s/%s/%s/associations?target=%s&type=%s", + createAlfredApiUrl("/nodes/%s/%s/%s/associations?target=%s&type=%s", nodeRefA.getStoreRefProtocol(), nodeRefA.getStoreRefId(), nodeRefA.getGuid(), - nodeRefB, c.apix(ContentModel.ASSOC_ORIGINAL)) + nodeRefB, c.alfredApi(ContentModel.ASSOC_ORIGINAL)) , null); serviceRegistry.getRetryingTransactionHelper() diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/BulkTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/BulkTest.java similarity index 99% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/BulkTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/BulkTest.java index bbe87594..1522f63d 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/BulkTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/BulkTest.java @@ -47,7 +47,7 @@ public class BulkTest extends RestV1BaseTest { public BulkTest() { // initialise the local beans alfrescoNodeService = serviceRegistry.getNodeService(); - nodeService = getBean(eu.xenit.alfred.api.alfresco.metadata.NodeService.class); // fetches APIX nodeService + nodeService = getBean(eu.xenit.alfred.api.alfresco.metadata.NodeService.class); // fetches AlfredApi nodeService } private String jsonObjectGetStringFromInt(JSONObject targetObject, String key) { diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CheckoutCheckinTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CheckoutCheckinTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CheckoutCheckinTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CheckoutCheckinTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CommentsTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CommentsTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CommentsTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CommentsTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/ConfigurationTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/ConfigurationTest.java similarity index 94% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/ConfigurationTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/ConfigurationTest.java index 67a0eba6..77390867 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/ConfigurationTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/ConfigurationTest.java @@ -44,7 +44,7 @@ public class ConfigurationTest extends RestV1BaseTest { private final INodeService nodeService; private final IContentService contentService; - private final IFileFolderService apixFileFolderService; + private final IFileFolderService alfredApiFileFolderService; private final NodeArchiveService nodeArchiveService; private final PermissionService permissionService; @@ -58,10 +58,10 @@ public ConfigurationTest() { permissionService = serviceRegistry.getPermissionService(); nodeArchiveService = getBean(NodeArchiveService.class); authenticationService = getBean("AuthenticationService", AuthenticationService.class); - // Apix beans - apixFileFolderService = getBean(IFileFolderService.class); + // AlfredApi beans + alfredApiFileFolderService = getBean(IFileFolderService.class); contentService = getBean(IContentService.class); - nodeService = getBean(eu.xenit.alfred.api.alfresco.metadata.NodeService.class); // fetches APIX nodeService + nodeService = getBean(eu.xenit.alfred.api.alfresco.metadata.NodeService.class); // fetches AlfredApi nodeService } @Before @@ -69,8 +69,8 @@ public void setup() { AuthenticationUtil.setAdminUserAsFullyAuthenticatedUser(); RetryingTransactionHelper.RetryingTransactionCallback txnWork = () -> { - NodeRef dataDictionary = apixFileFolderService.getDataDictionary(); - NodeRef testFolder = apixFileFolderService + NodeRef dataDictionary = alfredApiFileFolderService.getDataDictionary(); + NodeRef testFolder = alfredApiFileFolderService .createFolder(dataDictionary, "ConfigurationTests"); jsonNodeRef = nodeService @@ -88,7 +88,7 @@ public void setup() { ByteArrayInputStream otherContent = new ByteArrayInputStream("{\"contents\": \"other\"}".getBytes()); contentService.setContent(otherNodeRef, otherContent, "abc.json"); - NodeRef subFolder = apixFileFolderService.createFolder(testFolder, "subFolder"); + NodeRef subFolder = alfredApiFileFolderService.createFolder(testFolder, "subFolder"); yamlsubNodeRef = nodeService .createNode(subFolder, "sub.yaml", new QName(ContentModel.TYPE_CONTENT.toString())); @@ -223,8 +223,8 @@ public void testConfigurationSubdirectory() throws IOException, JSONException { public void cleanUp() { RetryingTransactionHelper.RetryingTransactionCallback txnWork = () -> { try { - NodeRef dataDictionary = apixFileFolderService.getDataDictionary(); - NodeRef testFolder = apixFileFolderService + NodeRef dataDictionary = alfredApiFileFolderService.getDataDictionary(); + NodeRef testFolder = alfredApiFileFolderService .getChildNodeRef(dataDictionary, "ConfigurationTests"); removeTestNode(new org.alfresco.service.cmr.repository.NodeRef(testFolder.toString())); } catch (RuntimeException ex) { diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CopyNodeTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CopyNodeTest.java similarity index 96% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CopyNodeTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CopyNodeTest.java index 729c8cfb..2b4435b4 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CopyNodeTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CopyNodeTest.java @@ -29,7 +29,7 @@ public void setup() { AuthenticationUtil.setAdminUserAsFullyAuthenticatedUser(); final HashMap initializedNodeRefs = init(); - mainTestFolder = c.apix(getMainTestFolder()); + mainTestFolder = c.alfredApi(getMainTestFolder()); copyFromFile = initializedNodeRefs.get(RestV1BaseTest.TESTFILE_NAME); copyFromFolder = initializedNodeRefs.get(RestV1BaseTest.TESTFOLDER_NAME); } @@ -55,7 +55,7 @@ public void testCopyFileNodeWithAspectsToRemove() { }, false, true); QName[] aspectsToRemove = new QName[1]; - aspectsToRemove[0] = c.apix(ContentModel.ASPECT_TEMPORARY); + aspectsToRemove[0] = c.alfredApi(ContentModel.ASPECT_TEMPORARY); CreateNodeOptions createNodeOptions = getCreateNodeOptions(mainTestFolder, null, null, null, null, aspectsToRemove, copyFromFile); @@ -125,7 +125,7 @@ public void testCopyFileDuplicateName() { @Test public void testCopyFolderDuplicateName() { final NodeRef childRef = iNodeService.getChildAssociations(mainTestFolder).get(0).getTarget(); - final String newName = iNodeService.getMetadata(childRef).getProperties().get(c.apix(ContentModel.PROP_NAME)) + final String newName = iNodeService.getMetadata(childRef).getProperties().get(c.alfredApi(ContentModel.PROP_NAME)) .get(0); CreateNodeOptions createNodeOptions = getCreateNodeOptions(mainTestFolder, newName, null, null, copyFromFolder); @@ -175,7 +175,7 @@ public void testCopyFolderInception() { @Test public void testCopyFolderTypeChange() { CreateNodeOptions createNodeOptions = getCreateNodeOptions(mainTestFolder, null, - c.apix(ContentModel.TYPE_CONTENT), null, copyFromFolder); + c.alfredApi(ContentModel.TYPE_CONTENT), null, copyFromFolder); transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { doPostNodes(createNodeOptions, HttpStatus.SC_INTERNAL_SERVER_ERROR, null, null); @@ -186,7 +186,7 @@ public void testCopyFolderTypeChange() { @Test public void testCopyFolderSubTyping() { CreateNodeOptions createNodeOptions = getCreateNodeOptions(mainTestFolder, null, - c.apix(ContentModel.TYPE_DICTIONARY_MODEL), null, copyFromFile); + c.alfredApi(ContentModel.TYPE_DICTIONARY_MODEL), null, copyFromFile); transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { doPostNodes(createNodeOptions, HttpStatus.SC_OK, null, null); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CreateNodeTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CreateNodeTest.java similarity index 91% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CreateNodeTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CreateNodeTest.java index c6af67ae..0c6ee61f 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CreateNodeTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/CreateNodeTest.java @@ -23,7 +23,7 @@ public void setup() { AuthenticationUtil.setAdminUserAsFullyAuthenticatedUser(); final HashMap initializedNodeRefs = init(); - mainTestFolder = c.apix(getMainTestFolder()); + mainTestFolder = c.alfredApi(getMainTestFolder()); parentTestFolder = initializedNodeRefs.get(RestV1BaseTest.TESTFOLDER_NAME); } @@ -31,7 +31,7 @@ public void setup() { public void testCreateFile() { String name = "newFile"; CreateNodeOptions createNodeOptions = getCreateNodeOptions(parentTestFolder, name, - c.apix(ContentModel.TYPE_CONTENT), null, null); + c.alfredApi(ContentModel.TYPE_CONTENT), null, null); NodeRef newRef = transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { return doPostNodes(createNodeOptions, HttpStatus.SC_OK, null, null); @@ -43,7 +43,7 @@ public void testCreateFile() { public void testCreateFolder() { String name = "newFolder"; CreateNodeOptions createNodeOptions = getCreateNodeOptions(parentTestFolder, name, - c.apix(ContentModel.TYPE_FOLDER), null, null); + c.alfredApi(ContentModel.TYPE_FOLDER), null, null); NodeRef newRef = transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { return doPostNodes(createNodeOptions, HttpStatus.SC_OK, null, null); @@ -69,7 +69,7 @@ public void testCreateFileWithProperties() { String name = "newFile1"; HashMap properties = getBasicProperties(); CreateNodeOptions createNodeOptions = getCreateNodeOptions(parentTestFolder, name, - c.apix(ContentModel.TYPE_CONTENT), properties, null); + c.alfredApi(ContentModel.TYPE_CONTENT), properties, null); NodeRef newRef = transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { return doPostNodes(createNodeOptions, HttpStatus.SC_OK, null, null); @@ -81,7 +81,7 @@ public void testCreateFileWithProperties() { public void testCreateFileDuplicateName() { String name = "duplicate"; CreateNodeOptions createNodeOptions = getCreateNodeOptions(parentTestFolder, name, - c.apix(ContentModel.TYPE_CONTENT), null, null); + c.alfredApi(ContentModel.TYPE_CONTENT), null, null); NodeRef newRef = transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { return doPostNodes(createNodeOptions, HttpStatus.SC_OK, null, null); @@ -97,7 +97,7 @@ public void testCreateFileDuplicateName() { public void testCreateNodeReturnsAccessDenied() { String name = "Forbidden"; CreateNodeOptions createNodeOptions = getCreateNodeOptions(mainTestFolder, name, - c.apix(ContentModel.TYPE_CONTENT), null, null); + c.alfredApi(ContentModel.TYPE_CONTENT), null, null); transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { doPostNodes(createNodeOptions, HttpStatus.SC_FORBIDDEN, diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/DictionaryTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/DictionaryTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/DictionaryTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/DictionaryTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MetadataTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MetadataTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MetadataTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MetadataTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MoveNodeTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MoveNodeTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MoveNodeTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/MoveNodeTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodeContentTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodeContentTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodeContentTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodeContentTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodesBaseTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodesBaseTest.java similarity index 97% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodesBaseTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodesBaseTest.java index ee74bb30..133fd404 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodesBaseTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/NodesBaseTest.java @@ -49,8 +49,8 @@ protected String getSimpleNodesUrl(String userName, String passWord) { protected HashMap getBasicProperties() { HashMap properties = new HashMap<>(); - properties.put(c.apix(ContentModel.PROP_TITLE), new String[]{"NewTitle"}); - properties.put(c.apix(ContentModel.PROP_DESCRIPTION), new String[]{"TestDescription"}); + properties.put(c.alfredApi(ContentModel.PROP_TITLE), new String[]{"NewTitle"}); + properties.put(c.alfredApi(ContentModel.PROP_DESCRIPTION), new String[]{"TestDescription"}); return properties; } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PathTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PathTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PathTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PathTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PeopleTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PeopleTest.java similarity index 92% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PeopleTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PeopleTest.java index 27719696..f4c8ed32 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PeopleTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PeopleTest.java @@ -71,12 +71,12 @@ public Object execute() throws Throwable { .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Object execute() throws Throwable { - nodeRef[0] = c.apix(self.alfrescoPersonService.createPerson(props)); + nodeRef[0] = c.alfredApi(self.alfrescoPersonService.createPerson(props)); return null; } }, false, true); - String url = createApixUrl("/people/%s/%s/%s", nodeRef[0].getStoreRefProtocol(), nodeRef[0].getStoreRefId(), + String url = createAlfredApiUrl("/people/%s/%s/%s", nodeRef[0].getStoreRefProtocol(), nodeRef[0].getStoreRefId(), nodeRef[0].getGuid()); HttpResponse httpResponse = Request.Get(url).execute().returnResponse(); @@ -93,7 +93,7 @@ public Object execute() throws Throwable { @Test public void testGetNonExistentPerson() throws IOException { final String userName = "NonexistentUsername"; - String url = createApixUrl("/people/%s", userName); + String url = createAlfredApiUrl("/people/%s", userName); HttpResponse httpResponse = Request.Get(url).execute().returnResponse(); Assert.assertEquals(httpResponse.getStatusLine().getStatusCode(), HttpStatus.SC_NOT_FOUND); @@ -103,7 +103,7 @@ public void testGetNonExistentPerson() throws IOException { @Test public void testGetSelf() throws IOException { final String userName = "-me-"; - String url = createApixUrl("/people?userName=%s", userName); + String url = createAlfredApiUrl("/people?userName=%s", userName); HttpResponse httpResponse = Request.Get(url).execute().returnResponse(); String result = EntityUtils.toString(httpResponse.getEntity()); Person person = new ObjectMapper().readValue(result, Person.class); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PermissionsTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PermissionsTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PermissionsTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/PermissionsTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/RestV1BaseTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/RestV1BaseTest.java similarity index 95% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/RestV1BaseTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/RestV1BaseTest.java index f0867ad2..c6c02217 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/RestV1BaseTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/RestV1BaseTest.java @@ -66,7 +66,7 @@ protected String getVersion() { return VERSION; } - protected String createApixUrl(String subUrl, Object... args) { + protected String createAlfredApiUrl(String subUrl, Object... args) { for (int i = 0; i < args.length; i++) { args[i] = URLEncoder.encodeUriComponent(args[i].toString()); } @@ -199,22 +199,22 @@ protected HashMap init(final String te new eu.xenit.alfred.api.data.NodeRef(testFolder.getNodeRef().toString())); FileInfo testNode = createTestNode(testFolder.getNodeRef(), TESTFILE_NAME, ContentModel.TYPE_CONTENT); NodeRef testNodeRef = testNode.getNodeRef(); - eu.xenit.alfred.api.data.NodeRef apixTestNodeRef = new eu.xenit.alfred.api.data.NodeRef(testNodeRef.toString()); - initializedNodeRefs.put(TESTFILE_NAME, apixTestNodeRef); + eu.xenit.alfred.api.data.NodeRef alfredApiTestNodeRef = new eu.xenit.alfred.api.data.NodeRef(testNodeRef.toString()); + initializedNodeRefs.put(TESTFILE_NAME, alfredApiTestNodeRef); FileInfo testFolder2 = createTestNode(mainTestFolder.getNodeRef(), TESTFOLDER2_NAME, ContentModel.TYPE_FOLDER); FileInfo testNode2 = createTestNode(testFolder2.getNodeRef(), TESTFILE2_NAME, ContentModel.TYPE_CONTENT); NodeRef testNodeRef2 = testNode2.getNodeRef(); - eu.xenit.alfred.api.data.NodeRef apixTestNodeRef2 = new eu.xenit.alfred.api.data.NodeRef(testNodeRef2.toString()); - initializedNodeRefs.put(TESTFILE2_NAME, apixTestNodeRef2); + eu.xenit.alfred.api.data.NodeRef alfredApiTestNodeRef2 = new eu.xenit.alfred.api.data.NodeRef(testNodeRef2.toString()); + initializedNodeRefs.put(TESTFILE2_NAME, alfredApiTestNodeRef2); FileInfo testNode3 = createTestNode(testFolder2.getNodeRef(), TESTFILE3_NAME, ContentModel.TYPE_CONTENT); NodeRef testNodeRef3 = testNode3.getNodeRef(); - eu.xenit.alfred.api.data.NodeRef apixTestNodeRef3 = new eu.xenit.alfred.api.data.NodeRef(testNodeRef3.toString()); - initializedNodeRefs.put(TESTFILE3_NAME, apixTestNodeRef3); + eu.xenit.alfred.api.data.NodeRef alfredApiTestNodeRef3 = new eu.xenit.alfred.api.data.NodeRef(testNodeRef3.toString()); + initializedNodeRefs.put(TESTFILE3_NAME, alfredApiTestNodeRef3); FileInfo noUserRightsFolder = createTestNode(mainTestFolder.getNodeRef(), NOUSERRIGHTS_FOLDER_NAME, ContentModel.TYPE_FOLDER); @@ -223,9 +223,9 @@ protected HashMap init(final String te ContentModel.TYPE_CONTENT); NodeRef noUserRightsNodeRef = noUserRightsNode.getNodeRef(); setPermissionInheritance(noUserRightsNodeRef, false); - eu.xenit.alfred.api.data.NodeRef apixNoUserRightsNodeRef = new eu.xenit.alfred.api.data.NodeRef( + eu.xenit.alfred.api.data.NodeRef alfredApiNoUserRightsNodeRef = new eu.xenit.alfred.api.data.NodeRef( noUserRightsNodeRef.toString()); - initializedNodeRefs.put(NOUSERRIGHTS_FILE_NAME, apixNoUserRightsNodeRef); + initializedNodeRefs.put(NOUSERRIGHTS_FILE_NAME, alfredApiNoUserRightsNodeRef); createUser(USERWITHOUTRIGHTS, USERWITHOUTRIGHTS, USERWITHOUTRIGHTS, USERWITHOUTRIGHTS_EMAIL); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/SetInheritParentPermissionsTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/SetInheritParentPermissionsTest.java similarity index 97% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/SetInheritParentPermissionsTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/SetInheritParentPermissionsTest.java index 04f4b54f..9c099c3d 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/SetInheritParentPermissionsTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/SetInheritParentPermissionsTest.java @@ -55,7 +55,7 @@ public void testSetInheritPermissionsRestFalse() throws IOException, Interrupted } private void setInheritUrl(final NodeRef nodeRef0, final boolean inherit) throws IOException, JSONException { - String url = makeAlfrescoBaseurl("admin", "admin") + "/apix/v1/nodes/" + nodeRef0.GetApixUrl() + String url = makeAlfrescoBaseurl("admin", "admin") + "/apix/v1/nodes/" + nodeRef0.GetAlfredApiUrl() + "/acl/inheritFromParent"; HttpPost httppost = new HttpPost(url); String body = "{\"inheritFromParent\":\"" + inherit + "\"}"; @@ -66,7 +66,7 @@ private void setInheritUrl(final NodeRef nodeRef0, final boolean inherit) throws } private void assertInheritUrl(final NodeRef nodeRef0, boolean value) throws IOException, JSONException { - String url = makeAlfrescoBaseurl("admin", "admin") + "/apix/v1/nodes/" + nodeRef0.GetApixUrl() + "/acl"; + String url = makeAlfrescoBaseurl("admin", "admin") + "/apix/v1/nodes/" + nodeRef0.GetAlfredApiUrl() + "/acl"; try (CloseableHttpClient httpclient = HttpClients.createDefault()) { CloseableHttpResponse response = httpclient.execute(new HttpGet(url)); String jsonResp = EntityUtils.toString(response.getEntity()); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionHistoryTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionHistoryTest.java similarity index 97% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionHistoryTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionHistoryTest.java index 83b0647e..ce86c831 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionHistoryTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionHistoryTest.java @@ -62,7 +62,7 @@ public void testGetVersionHistorySimpleNode() throws IOException { transactionService.getRetryingTransactionHelper() .doInTransaction(() -> { NodeRef testNode = initializedNodeRefs.get(RestV1BaseTest.TESTFILE3_NAME); - url[0] = createApixUrl("/versionhistory/%s/%s/%s/versions", testNode.getStoreRefProtocol(), + url[0] = createAlfredApiUrl("/versionhistory/%s/%s/%s/versions", testNode.getStoreRefProtocol(), testNode.getStoreRefId(), testNode.getGuid()); HashMap versionProperties = new HashMap<>(); versionProperties.put(VersionBaseModel.PROP_VERSION_TYPE, @@ -101,7 +101,7 @@ public void testSetVersionHistoryWithoutBody() throws IOException { final boolean defaultInitialVersion = dictionaryService.getProperty(ContentModel.PROP_INITIAL_VERSION) .getDefaultValue().equals("true"); - String versionHistoryUrl = createApixUrl("/versionhistory/%s/%s/%s", + String versionHistoryUrl = createAlfredApiUrl("/versionhistory/%s/%s/%s", initializedNodeRefs.get(RestV1BaseTest.TESTFILE_NAME).getStoreRefProtocol(), initializedNodeRefs.get(RestV1BaseTest.TESTFILE_NAME).getStoreRefId(), initializedNodeRefs.get(RestV1BaseTest.TESTFILE_NAME).getGuid()); @@ -150,7 +150,7 @@ public void testSetVersionHistoryWithoutBody() throws IOException { return null; }, true, true); - String versionHistoryUrl2 = createApixUrl("/versionhistory/%s/%s/%s", + String versionHistoryUrl2 = createAlfredApiUrl("/versionhistory/%s/%s/%s", initializedNodeRefs.get(RestV1BaseTest.TESTFILE2_NAME).getStoreRefProtocol(), initializedNodeRefs.get(RestV1BaseTest.TESTFILE2_NAME).getStoreRefId(), initializedNodeRefs.get(RestV1BaseTest.TESTFILE2_NAME).getGuid()); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/VersionTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/resources/cyrillic_message.msg b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/resources/cyrillic_message.msg similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/resources/cyrillic_message.msg rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/resources/cyrillic_message.msg diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/UploadFileTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/UploadFileTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/UploadFileTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/UploadFileTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/V1SearchWebscriptTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/V1SearchWebscriptTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/V1SearchWebscriptTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v1/tests/temp/V1SearchWebscriptTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/AllNodeInfoTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/AllNodeInfoTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/AllNodeInfoTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/AllNodeInfoTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/GroupTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/GroupTest.java similarity index 92% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/GroupTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/GroupTest.java index 008d5b6b..c9a6054a 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/GroupTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/GroupTest.java @@ -85,7 +85,7 @@ public Object execute() throws Throwable { @Override public Object execute() throws Throwable { for (int i = 0; i < 3; i++) { - c.apix(self.alfrescoPersonService.createPerson(propList.get(i))); + c.alfredApi(self.alfrescoPersonService.createPerson(propList.get(i))); } return null; } @@ -122,7 +122,7 @@ public Object execute() throws Throwable { @Test public void testNoUsersInGroup() throws IOException { - String url = createApixUrl("/groups/%s/people?immediate=true", groupIdentifier); + String url = createAlfredApiUrl("/groups/%s/people?immediate=true", groupIdentifier); System.out.println("About to http get"); HttpResponse httpResponse = Request.Get(url).execute().returnResponse(); HttpEntity entity = httpResponse.getEntity(); @@ -134,8 +134,8 @@ public void testNoUsersInGroup() throws IOException { @Test public void testAddUserToGroup() throws IOException { - String putUrl = createApixUrl("/groups/%s/people", groupIdentifier); - String getUrl = createApixUrl("/groups/%s/people?immediate=true", groupIdentifier); + String putUrl = createAlfredApiUrl("/groups/%s/people", groupIdentifier); + String getUrl = createAlfredApiUrl("/groups/%s/people?immediate=true", groupIdentifier); System.out.println("About to http put"); CloseableHttpClient client = HttpClients.createDefault(); HttpPut put = new HttpPut(putUrl); @@ -159,8 +159,8 @@ public void testAddUserToGroup() throws IOException { @Test public void testReplaceUsersInGroup() throws IOException { - String putUrl = createApixUrl("/groups/%s/people", groupIdentifier); - String getUrl = createApixUrl("/groups/%s/people?immediate=true", groupIdentifier); + String putUrl = createAlfredApiUrl("/groups/%s/people", groupIdentifier); + String getUrl = createAlfredApiUrl("/groups/%s/people?immediate=true", groupIdentifier); // Add first user @@ -201,8 +201,8 @@ public void testReplaceUsersInGroup() throws IOException { @Test public void testReplaceUsersWithSame() throws IOException { - String putUrl = createApixUrl("/groups/%s/people", groupIdentifier); - String getUrl = createApixUrl("/groups/%s/people?immediate=true", groupIdentifier); + String putUrl = createAlfredApiUrl("/groups/%s/people", groupIdentifier); + String getUrl = createAlfredApiUrl("/groups/%s/people?immediate=true", groupIdentifier); // Add first user @@ -235,8 +235,8 @@ public void testReplaceUsersWithSame() throws IOException { @Test public void testReplaceUsersWithSuperSet() throws IOException { - String putUrl = createApixUrl("/groups/%s/people", groupIdentifier); - String getUrl = createApixUrl("/groups/%s/people?immediate=true", groupIdentifier); + String putUrl = createAlfredApiUrl("/groups/%s/people", groupIdentifier); + String getUrl = createAlfredApiUrl("/groups/%s/people?immediate=true", groupIdentifier); // Add first user @@ -277,8 +277,8 @@ public void testReplaceUsersWithSuperSet() throws IOException { @Test public void testClearUsers() throws IOException { - String putUrl = createApixUrl("/groups/%s/people", groupIdentifier); - String getUrl = createApixUrl("/groups/%s/people?immediate=true", groupIdentifier); + String putUrl = createAlfredApiUrl("/groups/%s/people", groupIdentifier); + String getUrl = createAlfredApiUrl("/groups/%s/people?immediate=true", groupIdentifier); // Add two users diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/PeopleTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/PeopleTest.java similarity index 93% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/PeopleTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/PeopleTest.java index 5f7eb2e3..a53c10ee 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/PeopleTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/PeopleTest.java @@ -14,7 +14,7 @@ public class PeopleTest extends RestV2BaseTest { @Test public void testGetSelf() throws IOException { final String userName = "-me-"; - String url = createApixUrl("/people/%s", userName); + String url = createAlfredApiUrl("/people/%s", userName); HttpResponse httpResponse = Request.Get(url).execute().returnResponse(); String result = EntityUtils.toString(httpResponse.getEntity()); Person person = new ObjectMapper().readValue(result, Person.class); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/RestV2BaseTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/RestV2BaseTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/RestV2BaseTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/rest/v2/tests/RestV2BaseTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/JavaApiBaseTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/JavaApiBaseTest.java similarity index 87% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/JavaApiBaseTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/JavaApiBaseTest.java index d2625f4f..be4c65ca 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/JavaApiBaseTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/JavaApiBaseTest.java @@ -20,15 +20,15 @@ @Configuration public abstract class JavaApiBaseTest extends BaseApplicationContextTest { - //Apix Test model contstants - public static final String APIX_TESTCM_NAMESPACE = "http://test.apix.xenit.eu/model/content"; - public static final String APIX_TESTCM_PREFIX = "apixtest"; - public static final String APIX_TESTCM_PROP_SEARCHSERVICELIMITTEST_SHORTNAME = "searchServiceLimitTestProperty"; - public static final String APIX_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED = - APIX_TESTCM_PREFIX + ":" + APIX_TESTCM_PROP_SEARCHSERVICELIMITTEST_SHORTNAME; + //AlfredApi Test model contstants + public static final String ALFRED_API_TESTCM_NAMESPACE = "http://test.alfredapi.xenit.eu/model/content"; + public static final String ALFRED_API_TESTCM_PREFIX = "alfredapitest"; + public static final String ALFRED_API_TESTCM_PROP_SEARCHSERVICELIMITTEST_SHORTNAME = "searchServiceLimitTestProperty"; + public static final String ALFRED_API_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED = + ALFRED_API_TESTCM_PREFIX + ":" + ALFRED_API_TESTCM_PROP_SEARCHSERVICELIMITTEST_SHORTNAME; private static final Logger logger = LoggerFactory.getLogger(JavaApiBaseTest.class); - private static final String mainTestFolderName = "ApixMainTestFolder"; + private static final String mainTestFolderName = "AlfredApiMainTestFolder"; protected NodeRef getNodeAtPath(String path) { diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/categories/CategoryServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/categories/CategoryServiceTest.java similarity index 98% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/categories/CategoryServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/categories/CategoryServiceTest.java index 1c20b8f8..8fac8c15 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/categories/CategoryServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/categories/CategoryServiceTest.java @@ -32,7 +32,7 @@ public CategoryServiceTest() { @Before public void Setup() { AuthenticationUtil.setFullyAuthenticatedUser(ADMIN_USER_NAME); - generalClassifiableQName = c.apix(ContentModel.ASPECT_GEN_CLASSIFIABLE); + generalClassifiableQName = c.alfredApi(ContentModel.ASPECT_GEN_CLASSIFIABLE); } /** diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/comments/CommentServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/comments/CommentServiceTest.java similarity index 68% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/comments/CommentServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/comments/CommentServiceTest.java index cff326c2..56310bea 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/comments/CommentServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/comments/CommentServiceTest.java @@ -48,9 +48,9 @@ public void setupComments() { public void testGetDocumentForComment() { NodeRef commentNode = alfrescoCommentService .createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); - eu.xenit.alfred.api.data.NodeRef documentApixNode = commentService - .getTargetDocumentForComment(c.apix(commentNode)); - assertEquals(c.apix(testDocumentNode.getNodeRef()), documentApixNode); + eu.xenit.alfred.api.data.NodeRef documentAlfredApiNode = commentService + .getTargetDocumentForComment(c.alfredApi(commentNode)); + assertEquals(c.alfredApi(testDocumentNode.getNodeRef()), documentAlfredApiNode); } @Test @@ -58,26 +58,26 @@ public void testGetCommentsWithHasMoreIsFalse() { NodeService alfrescoNodeService = serviceRegistry.getNodeService(); NodeRef commentNode = alfrescoCommentService .createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); - Conversation actual = commentService.getComments(c.apix(testDocumentNode.getNodeRef()), 0, 10); + Conversation actual = commentService.getComments(c.alfredApi(testDocumentNode.getNodeRef()), 0, 10); assertTrue(actual.isCreatable()); assertFalse(actual.hasMore()); assertEquals(1, actual.getComments().size()); - Comment apixComment = actual.getComments().get(0); - assertEquals(c.apix(commentNode), apixComment.getId()); - assertEquals(commentTitle, apixComment.getTitle()); - assertEquals(commentContent, apixComment.getContent()); + Comment alfredApiComment = actual.getComments().get(0); + assertEquals(c.alfredApi(commentNode), alfredApiComment.getId()); + assertEquals(commentTitle, alfredApiComment.getTitle()); + assertEquals(commentContent, alfredApiComment.getContent()); Map commentProperties = alfrescoNodeService.getProperties(commentNode); - assertEquals(commentProperties.get(ContentModel.PROP_CREATOR), apixComment.getCreatedBy()); - assertEquals(commentProperties.get(ContentModel.PROP_MODIFIER), apixComment.getModifiedBy()); - assertTrue(apixComment.isEditable()); - assertTrue(apixComment.isDeletable()); + assertEquals(commentProperties.get(ContentModel.PROP_CREATOR), alfredApiComment.getCreatedBy()); + assertEquals(commentProperties.get(ContentModel.PROP_MODIFIER), alfredApiComment.getModifiedBy()); + assertTrue(alfredApiComment.isEditable()); + assertTrue(alfredApiComment.isDeletable()); } @Test public void testFetCommentsWithHasMoreIsTrueWithPageSize() { alfrescoCommentService.createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); alfrescoCommentService.createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); - Conversation actual = commentService.getComments(c.apix(testDocumentNode.getNodeRef()), 0, 1); + Conversation actual = commentService.getComments(c.alfredApi(testDocumentNode.getNodeRef()), 0, 1); assertTrue(actual.hasMore()); assertEquals(1, actual.getComments().size()); } @@ -88,16 +88,16 @@ public void testGetCommentsWithSkipCountWithPageSize() { NodeRef oldestNode = alfrescoCommentService .createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); alfrescoCommentService.createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); - Conversation actual = commentService.getComments(c.apix(testDocumentNode.getNodeRef()), 1, 1); + Conversation actual = commentService.getComments(c.alfredApi(testDocumentNode.getNodeRef()), 1, 1); assertEquals(1, actual.getComments().size()); - assertEquals(c.apix(oldestNode), actual.getComments().get(0).getId()); + assertEquals(c.alfredApi(oldestNode), actual.getComments().get(0).getId()); } @Test public void testAddNewComment() { - eu.xenit.alfred.api.data.NodeRef apixTestDocNode = c.apix(testDocumentNode.getNodeRef()); - Comment newComment = commentService.addNewComment(apixTestDocNode, commentContent); - Conversation actual = commentService.getComments(apixTestDocNode, 0, 10); + eu.xenit.alfred.api.data.NodeRef alfredApiTestDocNode = c.alfredApi(testDocumentNode.getNodeRef()); + Comment newComment = commentService.addNewComment(alfredApiTestDocNode, commentContent); + Conversation actual = commentService.getComments(alfredApiTestDocNode, 0, 10); assertEquals(1, actual.getComments().size()); assertEquals(newComment, actual.getComments().get(0)); } @@ -106,23 +106,23 @@ public void testAddNewComment() { public void testUpdateComment() { NodeRef alfrescoCommentNode = alfrescoCommentService .createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); - eu.xenit.alfred.api.data.NodeRef apixCommentNode = c.apix(alfrescoCommentNode); + eu.xenit.alfred.api.data.NodeRef alfredApiCommentNode = c.alfredApi(alfrescoCommentNode); String newCommentContent = "New Content"; - commentService.updateComment(apixCommentNode, newCommentContent); - eu.xenit.alfred.api.data.NodeRef apixTestDocNode = c.apix(testDocumentNode.getNodeRef()); - Conversation actual = commentService.getComments(apixTestDocNode, 0, 1); + commentService.updateComment(alfredApiCommentNode, newCommentContent); + eu.xenit.alfred.api.data.NodeRef alfredApiTestDocNode = c.alfredApi(testDocumentNode.getNodeRef()); + Conversation actual = commentService.getComments(alfredApiTestDocNode, 0, 1); assertEquals(1, actual.getComments().size()); assertEquals(newCommentContent, actual.getComments().get(0).getContent()); - assertEquals(apixCommentNode, actual.getComments().get(0).getId()); + assertEquals(alfredApiCommentNode, actual.getComments().get(0).getId()); } @Test public void testDeleteComment() { NodeRef alfrescoCommentNodeRef = alfrescoCommentService .createComment(testDocumentNode.getNodeRef(), commentTitle, commentContent, false); - commentService.deleteComment(c.apix(alfrescoCommentNodeRef)); + commentService.deleteComment(c.alfredApi(alfrescoCommentNodeRef)); assertEquals(0, - commentService.getComments(c.apix(testDocumentNode.getNodeRef()), 0, 10).getComments() + commentService.getComments(c.alfredApi(testDocumentNode.getNodeRef()), 0, 10).getComments() .size()); } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/content/ContentServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/content/ContentServiceTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/content/ContentServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/content/ContentServiceTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/dictionary/DictionaryServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/dictionary/DictionaryServiceTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/dictionary/DictionaryServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/dictionary/DictionaryServiceTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/filefolder/FileFolderServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/filefolder/FileFolderServiceTest.java similarity index 86% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/filefolder/FileFolderServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/filefolder/FileFolderServiceTest.java index b26e49b7..ac4170ea 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/filefolder/FileFolderServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/filefolder/FileFolderServiceTest.java @@ -30,14 +30,14 @@ */ public class FileFolderServiceTest extends JavaApiBaseTest { - private final static Logger logger = LoggerFactory.getLogger(JavaApiBaseTest.class); + private final static Logger logger = LoggerFactory.getLogger(FileFolderServiceTest.class); - private static final String COMPANY_HOME_FOLDER_PATH = "/Company Home/ApixMainTestFolder"; - private static final String TEST_NODE_QNAME_PATH = "/app:company_home/cm:ApixMainTestFolder/cm:testnode"; + private static final String COMPANY_HOME_FOLDER_PATH = "/Company Home/AlfredApiMainTestFolder"; + private static final String TEST_NODE_QNAME_PATH = "/app:company_home/cm:AlfredApiMainTestFolder/cm:testnode"; StoreRef alfStoreRef = new StoreRef("workspace", "SpacesStore"); - eu.xenit.alfred.api.data.StoreRef apixStoreRef = new eu.xenit.alfred.api.data.StoreRef("workspace", "SpacesStore"); + eu.xenit.alfred.api.data.StoreRef alfredApiStoreRef = new eu.xenit.alfred.api.data.StoreRef("workspace", "SpacesStore"); private final IFileFolderService service; private final FileFolderService fileFolderService; @@ -94,8 +94,8 @@ public void TestGetDisplayPath() { } catch (InterruptedException e) { Assert.fail(String.format("Interupted while awaiting solr synced state. Exception: %s", e)); } - String displayPath = this.service.getPath(c.apix(testNode.getNodeRef())).getDisplayPath(); - logger.debug("DisplayPath: " + displayPath); + String displayPath = this.service.getPath(c.alfredApi(testNode.getNodeRef())).getDisplayPath(); + logger.error("DisplayPath: " + displayPath); assertNotNull(displayPath); assertEquals(displayPath, COMPANY_HOME_FOLDER_PATH); } @@ -117,7 +117,7 @@ public void TestGetQNamePath() { } catch (InterruptedException e) { Assert.fail(String.format("Interupted while awaiting solr synced state. Exception: %s", e)); } - String qNamePath = this.service.getPath(c.apix(testNode.getNodeRef())).getQnamePath(); + String qNamePath = this.service.getPath(c.alfredApi(testNode.getNodeRef())).getQnamePath(); logger.debug("QNamePath: " + qNamePath); assertNotNull(qNamePath); assertEquals(qNamePath, TEST_NODE_QNAME_PATH); @@ -141,13 +141,13 @@ public void testCreateFolder() { FileInfo testFolder = this.createTestFolder(mainTestFolder.getNodeRef(), "parentfolder"); try { - eu.xenit.alfred.api.data.NodeRef parentNodeRef = c.apix(testFolder.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef parentNodeRef = c.alfredApi(testFolder.getNodeRef()); String folderName = "testFolder"; assertFalse(this.service.existsFolder(parentNodeRef, folderName)); eu.xenit.alfred.api.data.NodeRef folderNodeRef = this.service - .createFolder(c.apix(testFolder.getNodeRef()), folderName); + .createFolder(c.alfredApi(testFolder.getNodeRef()), folderName); assertTrue(this.service.existsFolder(parentNodeRef, folderName)); @@ -173,8 +173,8 @@ public void testCreateDeepFolder() { FileInfo testSubFolder = this.createTestFolder(testFolder.getNodeRef(), parentSubFolderName); try { - eu.xenit.alfred.api.data.NodeRef parentNodeRef = c.apix(testFolder.getNodeRef()); - eu.xenit.alfred.api.data.NodeRef parentSubFolderNodeRef = c.apix(testSubFolder.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef parentNodeRef = c.alfredApi(testFolder.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef parentSubFolderNodeRef = c.alfredApi(testSubFolder.getNodeRef()); String folderName = "testDeepFolder"; assertTrue(this.service.existsFolder(parentNodeRef, parentSubFolderName)); @@ -199,18 +199,18 @@ public void testCreateDeepFolder() { @Test public void testGetCompanyHome() { NodeRef alfRef = repository.getCompanyHome(); - eu.xenit.alfred.api.data.NodeRef apixRef = service.getCompanyHome(); - eu.xenit.alfred.api.data.NodeRef check = c.apix(alfRef); - assertEquals(apixRef.getGuid(), check.getGuid()); - assertEquals(apixRef.getStoreRefId(), check.getStoreRefId()); - assertEquals(apixRef.getStoreRefProtocol(), check.getStoreRefProtocol()); - assertEquals(apixRef.toString(), check.toString()); + eu.xenit.alfred.api.data.NodeRef alfredApiRef = service.getCompanyHome(); + eu.xenit.alfred.api.data.NodeRef check = c.alfredApi(alfRef); + assertEquals(alfredApiRef.getGuid(), check.getGuid()); + assertEquals(alfredApiRef.getStoreRefId(), check.getStoreRefId()); + assertEquals(alfredApiRef.getStoreRefProtocol(), check.getStoreRefProtocol()); + assertEquals(alfredApiRef.toString(), check.toString()); } @Test public void TestGetRootFolder() { assertEquals( - service.getRootFolder(apixStoreRef).toString(), + service.getRootFolder(alfredApiStoreRef).toString(), alfrescoNodeService.getRootNode(alfStoreRef).toString()); } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/AlfrescoPropertyConvertorTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/AlfrescoPropertyConvertorTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/AlfrescoPropertyConvertorTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/AlfrescoPropertyConvertorTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/NodeServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/NodeServiceTest.java similarity index 87% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/NodeServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/NodeServiceTest.java index 6a2d2d74..75207351 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/NodeServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/metadata/NodeServiceTest.java @@ -59,7 +59,7 @@ public class NodeServiceTest extends JavaApiBaseTest { private final static Logger logger = LoggerFactory.getLogger(NodeServiceTest.class); private static final String TEXT_MIMETYPE = "text/plain"; StoreRef alfStoreRef = new StoreRef("workspace", "SpacesStore"); - eu.xenit.alfred.api.data.StoreRef apixStoreRef = new eu.xenit.alfred.api.data.StoreRef("workspace", "SpacesStore"); + eu.xenit.alfred.api.data.StoreRef alfredApiStoreRef = new eu.xenit.alfred.api.data.StoreRef("workspace", "SpacesStore"); private final INodeService service; private final ContentService contentService; @@ -103,12 +103,12 @@ public void Setup() { // changes.setPropertiesToAdd(props); // //// NodeMetadata m = serviceRegistry.getTransactionService().getRetryingTransactionHelper() -//// .doInTransaction(() -> service.setMetadata(c.apix(noderef), changes), false, true); +//// .doInTransaction(() -> service.setMetadata(c.alfredApi(noderef), changes), false, true); // // NodeMetadata m = serviceRegistry.getTransactionService().getRetryingTransactionHelper().doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { // @Override // public NodeMetadata execute() throws Throwable { -// return service.setMetadata(c.apix(noderef), changes); +// return service.setMetadata(c.alfredApi(noderef), changes); // } // }, false, true); // @@ -148,16 +148,16 @@ public void TestSetMetadata() { assertTrue(hasTemporaryAspect); assertEquals(ContentModel.TYPE_CONTENT.toString(), nameType.toString()); - eu.xenit.alfred.api.data.NodeRef testNodeRef = c.apix(testNode.getNodeRef()); - eu.xenit.alfred.api.data.NodeRef testNodeRef2 = c.apix(testNode2.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef testNodeRef = c.alfredApi(testNode.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef testNodeRef2 = c.alfredApi(testNode2.getNodeRef()); eu.xenit.alfred.api.data.QName[] aspectsToRemove = new eu.xenit.alfred.api.data.QName[]{ - c.apix(ContentModel.ASPECT_VERSIONABLE), c.apix(ContentModel.ASPECT_TEMPORARY)}; + c.alfredApi(ContentModel.ASPECT_VERSIONABLE), c.alfredApi(ContentModel.ASPECT_TEMPORARY)}; Map propertiesToSet = new HashMap<>(); - propertiesToSet.put(c.apix(ContentModel.PROP_NAME), new String[]{"newName"}); - propertiesToSet.put(c.apix(ContentModel.PROP_ADDRESSEES), new String[]{"addressee1", "addressee2"}); + propertiesToSet.put(c.alfredApi(ContentModel.PROP_NAME), new String[]{"newName"}); + propertiesToSet.put(c.alfredApi(ContentModel.PROP_ADDRESSEES), new String[]{"addressee1", "addressee2"}); - MetadataChanges changes = new MetadataChanges(c.apix(ContentModel.TYPE_CONTENT), + MetadataChanges changes = new MetadataChanges(c.alfredApi(ContentModel.TYPE_CONTENT), null, aspectsToRemove, propertiesToSet); this.service.setMetadata(testNodeRef, changes); @@ -180,7 +180,7 @@ public void TestSetMetadata() { assertEquals(ContentModel.TYPE_CONTENT.toString(), nameType.toString()); eu.xenit.alfred.api.data.QName[] aspectsToAdd = new eu.xenit.alfred.api.data.QName[]{ - c.apix(ContentModel.ASPECT_VERSIONABLE), c.apix(ContentModel.ASPECT_TEMPORARY)}; + c.alfredApi(ContentModel.ASPECT_VERSIONABLE), c.alfredApi(ContentModel.ASPECT_TEMPORARY)}; changes = new MetadataChanges(null, aspectsToAdd, null, null); this.service.setMetadata(testNodeRef, changes); @@ -217,11 +217,11 @@ public void TestSetAssociations() { assertEquals("testNode", originalName); assertTrue(assocs.isEmpty()); - eu.xenit.alfred.api.data.NodeRef testNodeRef = c.apix(testNode.getNodeRef()); - eu.xenit.alfred.api.data.NodeRef testNodeRef2 = c.apix(testNode2.getNodeRef()); - eu.xenit.alfred.api.data.NodeRef testNodeRef3 = c.apix(testNode3.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef testNodeRef = c.alfredApi(testNode.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef testNodeRef2 = c.alfredApi(testNode2.getNodeRef()); + eu.xenit.alfred.api.data.NodeRef testNodeRef3 = c.alfredApi(testNode3.getNodeRef()); - service.createAssociation(testNodeRef, testNodeRef2, c.apix(ContentModel.ASSOC_ORIGINAL)); + service.createAssociation(testNodeRef, testNodeRef2, c.alfredApi(ContentModel.ASSOC_ORIGINAL)); assocs = this.alfrescoNodeService.getTargetAssocs(testNode.getNodeRef(), RegexQNamePattern.MATCH_ALL); @@ -232,9 +232,9 @@ public void TestSetAssociations() { assertEquals(testNodeRef.toString(), assoc.getSourceRef().toString()); assertEquals(testNodeRef2.toString(), assoc.getTargetRef().toString()); - service.createAssociation(testNodeRef, testNodeRef2, c.apix(ContentModel.ASSOC_ATTACHMENTS)); + service.createAssociation(testNodeRef, testNodeRef2, c.alfredApi(ContentModel.ASSOC_ATTACHMENTS)); - service.removeAssociation(testNodeRef, testNodeRef2, c.apix(ContentModel.ASSOC_ORIGINAL)); + service.removeAssociation(testNodeRef, testNodeRef2, c.alfredApi(ContentModel.ASSOC_ORIGINAL)); assocs = this.alfrescoNodeService.getTargetAssocs(testNode.getNodeRef(), RegexQNamePattern.MATCH_ALL); @@ -245,7 +245,7 @@ public void TestSetAssociations() { assertEquals(testNodeRef.toString(), assoc.getSourceRef().toString()); assertEquals(testNodeRef2.toString(), assoc.getTargetRef().toString()); - service.createAssociation(testNodeRef, testNodeRef3, c.apix(ContentModel.ASSOC_ORIGINAL)); + service.createAssociation(testNodeRef, testNodeRef3, c.alfredApi(ContentModel.ASSOC_ORIGINAL)); assocs = this.alfrescoNodeService.getTargetAssocs(testNode.getNodeRef(), RegexQNamePattern.MATCH_ALL); assertEquals(2, assocs.size()); @@ -256,16 +256,16 @@ public void TestSetAssociations() { @Test public void TestGetMetadata() { -// java.util.List metadatas = service.getMetadata(c.apix(roots.stream().collect(Collectors.toList()))); +// java.util.List metadatas = service.getMetadata(c.alfredApi(roots.stream().collect(Collectors.toList()))); // assertTrue(roots.stream().allMatch(p -> metadatas.stream().anyMatch(m -> m.id.equals(p.toString())))); // assertTrue(metadatas.stream().allMatch(m -> roots.stream().anyMatch(p -> m.id.equals(p.toString())))); - NodeMetadata metadatas = service.getMetadata(c.apix(roots.iterator().next())); + NodeMetadata metadatas = service.getMetadata(c.alfredApi(roots.iterator().next())); logger.debug(metadatas.toString().replaceAll(",", ",\n")); - assertEquals(c.apix(roots.iterator().next()), metadatas.getId()); + assertEquals(c.alfredApi(roots.iterator().next()), metadatas.getId()); - assertTrue(metadatas.getProperties().containsKey(c.apix(ContentModel.PROP_NAME))); + assertTrue(metadatas.getProperties().containsKey(c.alfredApi(ContentModel.PROP_NAME))); } private Boolean nodeIsInMetaList(NodeRef node, List metadatas) { @@ -310,7 +310,7 @@ public void TestLoadMetadata() { NodeRef catRef = getNodeAtPath("/cm:generalclassifiable/cm:Regions/cm:EUROPE"); logger.debug("catref: " + catRef); // - categoryService.classifyNode(c.apix(ref), c.apix(catRef)); + categoryService.classifyNode(c.alfredApi(ref), c.alfredApi(catRef)); } @@ -350,11 +350,11 @@ public void testGetChildAssociations() { FileInfo testNode = this.createTestNode(testFolder.getNodeRef(), "testNode"); try { List childAssocs = this.service - .getChildAssociations(c.apix(testFolder.getNodeRef())); + .getChildAssociations(c.alfredApi(testFolder.getNodeRef())); assertEquals(childAssocs.size(), 1); for (NodeAssociation childAssoc : childAssocs) { - assertEquals(childAssoc.getSource().toString(), c.apix(testFolder.getNodeRef()).toString()); - assertEquals(childAssoc.getTarget().toString(), c.apix(testNode.getNodeRef()).toString()); + assertEquals(childAssoc.getSource().toString(), c.alfredApi(testFolder.getNodeRef()).toString()); + assertEquals(childAssoc.getTarget().toString(), c.alfredApi(testNode.getNodeRef()).toString()); assertEquals(childAssoc.getType().toString(), ContentModel.ASSOC_CONTAINS.toString()); } } finally { @@ -373,11 +373,11 @@ public void testGetParentAssociations() { FileInfo testNode = this.createTestNode(testFolder.getNodeRef(), "testNode"); try { List parentAssocs = this.service - .getParentAssociations(c.apix(testNode.getNodeRef())); + .getParentAssociations(c.alfredApi(testNode.getNodeRef())); assertEquals(parentAssocs.size(), 1); for (NodeAssociation parentAssoc : parentAssocs) { - assertEquals(parentAssoc.getSource().toString(), c.apix(testNode.getNodeRef()).toString()); - assertEquals(parentAssoc.getTarget().toString(), c.apix(testFolder.getNodeRef()).toString()); + assertEquals(parentAssoc.getSource().toString(), c.alfredApi(testNode.getNodeRef()).toString()); + assertEquals(parentAssoc.getTarget().toString(), c.alfredApi(testFolder.getNodeRef()).toString()); assertEquals(parentAssoc.getType().toString(), ContentModel.ASSOC_CONTAINS.toString()); } } finally { @@ -402,11 +402,11 @@ public void testGetPeerAssociations() { this.alfrescoNodeService.createAssociation(testNode.getNodeRef(), copyNodeRef, ContentModel.ASSOC_ORIGINAL); // Test for peerassociations as fetched from the source - List peerAssociations = this.service.getTargetAssociations(c.apix(testNode.getNodeRef())); + List peerAssociations = this.service.getTargetAssociations(c.alfredApi(testNode.getNodeRef())); assertPeerAssociation(testNode.getNodeRef(), copyNodeRef, peerAssociations); // Test for peerassociations as fetched from the target - peerAssociations = this.service.getSourceAssociations(c.apix(copyNodeRef)); + peerAssociations = this.service.getSourceAssociations(c.alfredApi(copyNodeRef)); assertPeerAssociation(testNode.getNodeRef(), copyNodeRef, peerAssociations); } finally { @@ -435,11 +435,11 @@ public void testCopyNode() { FileInfo testFolder = this.createTestFolder(mainTestFolder.getNodeRef(), "testfolder"); FileInfo testNode = this.createTestNode(mainTestFolder.getNodeRef(), "testnode"); try { - logger.debug("sourceNode: " + c.apix(testNode.getNodeRef())); - logger.debug("targetNode: " + c.apix(testFolder.getNodeRef())); + logger.debug("sourceNode: " + c.alfredApi(testNode.getNodeRef())); + logger.debug("targetNode: " + c.alfredApi(testFolder.getNodeRef())); - eu.xenit.alfred.api.data.NodeRef copiedNodeRef = this.service.copyNode(c.apix(testNode.getNodeRef()), - c.apix(testFolder.getNodeRef()), + eu.xenit.alfred.api.data.NodeRef copiedNodeRef = this.service.copyNode(c.alfredApi(testNode.getNodeRef()), + c.alfredApi(testFolder.getNodeRef()), true); assertNotNull(copiedNodeRef); @@ -463,7 +463,7 @@ public void testMoveNode() { FileInfo testNode = this.createTestNode(mainTestFolder.getNodeRef(), "testnode"); try { - this.service.moveNode(c.apix(testNode.getNodeRef()), c.apix(testFolder.getNodeRef())); + this.service.moveNode(c.alfredApi(testNode.getNodeRef()), c.alfredApi(testFolder.getNodeRef())); assertEquals(this.alfrescoNodeService.getPrimaryParent(testNode.getNodeRef()).getParentRef().toString(), testFolder.getNodeRef().toString()); } finally { @@ -481,7 +481,7 @@ public void testCreateNode() { FileInfo testFolder = this.createTestFolder(mainTestFolder.getNodeRef(), "testfolder"); try { eu.xenit.alfred.api.data.NodeRef createdNodeRef = this.service - .createNode(c.apix(testFolder.getNodeRef()), "testnode", c.apix(ContentModel.TYPE_CONTENT)); + .createNode(c.alfredApi(testFolder.getNodeRef()), "testnode", c.alfredApi(ContentModel.TYPE_CONTENT)); assertNotNull(createdNodeRef); assertEquals( this.alfrescoNodeService.getPrimaryParent(c.alfresco(createdNodeRef)).getParentRef().toString(), @@ -505,24 +505,24 @@ public void testCreateNodeCustomTypeWithRequiredProperties() { FileInfo testFolder = this.createTestFolder(mainTestFolder.getNodeRef(), "testfolder"); Map propertiesToSet = new HashMap<>(); - propertiesToSet.put(c.apix(ContentModel.PROP_NAME), new String[]{"newName"}); + propertiesToSet.put(c.alfredApi(ContentModel.PROP_NAME), new String[]{"newName"}); // mandatory property to set. - propertiesToSet.put(new eu.xenit.alfred.api.data.QName("{http://test.apix.xenit.eu/model/content}documentStatus"), + propertiesToSet.put(new eu.xenit.alfred.api.data.QName("{http://test.alfredapi.xenit.eu/model/content}documentStatus"), new String[]{"Draft"}); // custom type containing the mandatory property. eu.xenit.alfred.api.data.QName type = new eu.xenit.alfred.api.data.QName( - "{http://test.apix.xenit.eu/model/content}withMandatoryPropDocument"); + "{http://test.alfredapi.xenit.eu/model/content}withMandatoryPropDocument"); try { eu.xenit.alfred.api.data.NodeRef createdNodeRef = this.service - .createNode(c.apix(testFolder.getNodeRef()), propertiesToSet, null, null, type, null); + .createNode(c.alfredApi(testFolder.getNodeRef()), propertiesToSet, null, null, type, null); assertNotNull(createdNodeRef); assertEquals( this.alfrescoNodeService.getPrimaryParent(c.alfresco(createdNodeRef)).getParentRef().toString(), testFolder.getNodeRef().toString()); - assertEquals(c.apix(this.alfrescoNodeService.getType(c.alfresco(createdNodeRef))), type); + assertEquals(c.alfredApi(this.alfrescoNodeService.getType(c.alfresco(createdNodeRef))), type); } finally { this.removeTestNode(mainTestFolder.getNodeRef()); } @@ -549,13 +549,13 @@ public Void execute() throws Throwable { final NodeRef companyHomeRef = repository.getCompanyHome(); final Map propertiesToSet = new HashMap<>(); propertiesToSet - .put(c.apix(ContentModel.PROP_NAME), new String[]{"newNameWithoutMandatory"}); + .put(c.alfredApi(ContentModel.PROP_NAME), new String[]{"newNameWithoutMandatory"}); final eu.xenit.alfred.api.data.QName type = new eu.xenit.alfred.api.data.QName( - "{http://test.apix.xenit.eu/model/content}withMandatoryPropDocument"); + "{http://test.alfredapi.xenit.eu/model/content}withMandatoryPropDocument"); FileInfo mainTestFolder = self.createMainTestFolder(companyHomeRef); FileInfo testFolder = self.createTestFolder(mainTestFolder.getNodeRef(), "testfolder2"); - self.service.createNode(c.apix(testFolder.getNodeRef()), propertiesToSet, null, null, type, + self.service.createNode(c.alfredApi(testFolder.getNodeRef()), propertiesToSet, null, null, type, null); return null; } @@ -589,10 +589,10 @@ public void testCreateReadContent() throws Exception { // Create node with content. Map propertiesToSet = new HashMap<>(); - propertiesToSet.put(c.apix(ContentModel.PROP_NAME), new String[]{"nodeWithContent"}); + propertiesToSet.put(c.alfredApi(ContentModel.PROP_NAME), new String[]{"nodeWithContent"}); eu.xenit.alfred.api.data.NodeRef createdNodeRef = this.service - .createNode(c.apix(testFolder.getNodeRef()), propertiesToSet, null, null, - c.apix(ContentModel.TYPE_CONTENT), + .createNode(c.alfredApi(testFolder.getNodeRef()), propertiesToSet, null, null, + c.alfredApi(ContentModel.TYPE_CONTENT), content); // re-read content of the node. @@ -625,27 +625,27 @@ public void testCreateNodeWithMetadata() throws UnsupportedEncodingException { //properties to set Map propertiesToSet = new HashMap<>(); - propertiesToSet.put(c.apix(ContentModel.PROP_NAME), new String[]{"nodeWithContent"}); + propertiesToSet.put(c.alfredApi(ContentModel.PROP_NAME), new String[]{"nodeWithContent"}); eu.xenit.alfred.api.data.QName documentStatusQname = - new eu.xenit.alfred.api.data.QName("{http://test.apix.xenit.eu/model/content}documentStatus"); + new eu.xenit.alfred.api.data.QName("{http://test.alfredapi.xenit.eu/model/content}documentStatus"); propertiesToSet.put(documentStatusQname, new String[]{"Draft"}); //aspects to add eu.xenit.alfred.api.data.QName[] aspectsToAdd = new eu.xenit.alfred.api.data.QName[1]; - aspectsToAdd[0] = c.apix(ContentModel.ASPECT_TEMPORARY); + aspectsToAdd[0] = c.alfredApi(ContentModel.ASPECT_TEMPORARY); //type to set eu.xenit.alfred.api.data.QName type = new eu.xenit.alfred.api.data.QName( - "{http://test.apix.xenit.eu/model/content}withMandatoryPropDocument"); + "{http://test.alfredapi.xenit.eu/model/content}withMandatoryPropDocument"); eu.xenit.alfred.api.data.NodeRef createdNodeRef = self.service.createNode( - c.apix(testFolder.getNodeRef()), propertiesToSet, aspectsToAdd, null, type, null); + c.alfredApi(testFolder.getNodeRef()), propertiesToSet, aspectsToAdd, null, type, null); assertNotNull(createdNodeRef); assertEquals( alfrescoNodeService.getPrimaryParent(c.alfresco(createdNodeRef)).getParentRef().toString(), testFolder.getNodeRef().toString()); - assertEquals(c.apix(alfrescoNodeService.getType(c.alfresco(createdNodeRef))), type); + assertEquals(c.alfredApi(alfrescoNodeService.getType(c.alfresco(createdNodeRef))), type); Map testProperties = alfrescoNodeService.getProperties(c.alfresco(createdNodeRef)); assertNotNull("the cm:name property could not be found", testProperties.get(ContentModel.PROP_NAME)); assertNotNull("", testProperties.get(c.alfresco(documentStatusQname))); @@ -667,7 +667,7 @@ public void testCheckoutCheckin() { assertTrue(this.versionService.isVersioned(testNode.getNodeRef())); eu.xenit.alfred.api.data.NodeRef workingCopy = this.service - .checkout(c.apix(testNode.getNodeRef()), c.apix(mainTestFolder.getNodeRef())); + .checkout(c.alfredApi(testNode.getNodeRef()), c.alfredApi(mainTestFolder.getNodeRef())); assertTrue(this.alfrescoNodeService.hasAspect(c.alfresco(workingCopy), ContentModel.ASPECT_WORKING_COPY)); VersionHistory initialVersionHistory = this.versionService.getVersionHistory(testNode.getNodeRef()); // Alfresco versionHistory seems to have different default behaviour, with a new node having the 1st history element present. @@ -694,7 +694,7 @@ public void testDeleteNode() { try { assertTrue(this.alfrescoNodeService.exists(testNode.getNodeRef())); - this.service.deleteNode(c.apix(testNode.getNodeRef())); + this.service.deleteNode(c.alfredApi(testNode.getNodeRef())); assertFalse(this.alfrescoNodeService.exists(testNode.getNodeRef())); } finally { this.removeTestNode(mainTestFolder.getNodeRef()); @@ -711,7 +711,7 @@ public void testCancelCheckout() { try { assertTrue(this.versionService.isVersioned(testNode.getNodeRef())); eu.xenit.alfred.api.data.NodeRef workingCopy = this.service - .checkout(c.apix(testNode.getNodeRef()), c.apix(mainTestFolder.getNodeRef())); + .checkout(c.alfredApi(testNode.getNodeRef()), c.alfredApi(mainTestFolder.getNodeRef())); assertTrue(this.alfrescoNodeService.exists(c.alfresco(workingCopy))); assertTrue(this.alfrescoNodeService.hasAspect(c.alfresco(workingCopy), ContentModel.ASPECT_WORKING_COPY)); @@ -734,7 +734,7 @@ public void testGetWorkingCopySource() { try { assertTrue(this.versionService.isVersioned(testNode.getNodeRef())); eu.xenit.alfred.api.data.NodeRef workingCopy = this.service - .checkout(c.apix(testNode.getNodeRef()), c.apix(mainTestFolder.getNodeRef())); + .checkout(c.alfredApi(testNode.getNodeRef()), c.alfredApi(mainTestFolder.getNodeRef())); assertTrue(this.alfrescoNodeService.exists(c.alfresco(workingCopy))); assertTrue(this.alfrescoNodeService.hasAspect(c.alfresco(workingCopy), ContentModel.ASPECT_WORKING_COPY)); @@ -759,8 +759,8 @@ public void TestFileUpload() throws IOException { try { InputStream inputStream = new FileInputStream(testFile); eu.xenit.alfred.api.data.NodeRef createdNodeRef = service - .createNode(c.apix(mainTestFolder.getNodeRef()), testFile.getName(), - c.apix(ContentModel.TYPE_CONTENT)); + .createNode(c.alfredApi(mainTestFolder.getNodeRef()), testFile.getName(), + c.alfredApi(ContentModel.TYPE_CONTENT)); logger.debug("Filename: " + testFile.getName()); service.setContent(createdNodeRef, inputStream, testFile.getName()); @@ -820,7 +820,7 @@ public void TestSetContent_ShortOverload() { 128, "UTF8", Locale.CHINA); - service.setContent(c.apix(testNode), apContentData); + service.setContent(c.alfredApi(testNode), apContentData); ContentData newData = (ContentData) alfNodeService.getProperty(testNode, ContentModel.PROP_CONTENT); assertEquals("www.mycontent.be", newData.getContentUrl()); assertEquals("text/plain", newData.getMimetype()); @@ -836,7 +836,7 @@ public void TestSetContent_ShortOverload() { @Test public void TestGetRootNode() { assertEquals( - service.getRootNode(apixStoreRef).toString(), + service.getRootNode(alfredApiStoreRef).toString(), alfrescoNodeService.getRootNode(alfStoreRef).toString()); } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/people/PeopleServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/people/PeopleServiceTest.java similarity index 98% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/people/PeopleServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/people/PeopleServiceTest.java index 2295939c..0b7a8dfa 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/people/PeopleServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/people/PeopleServiceTest.java @@ -76,7 +76,7 @@ public Void execute() throws Throwable { public Void execute() throws Throwable { NodeRef person = alfrescoPersonService.createPerson(props); - Person p = peopleService.GetPerson(c.apix(person)); + Person p = peopleService.GetPerson(c.alfredApi(person)); assertEquals(p.getEmailAddress(), email); assertEquals(p.getFirstName(), firstName); assertEquals(p.getLastName(), lastName); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/permissions/PermissionServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/permissions/PermissionServiceTest.java similarity index 95% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/permissions/PermissionServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/permissions/PermissionServiceTest.java index 60293b00..acacb164 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/permissions/PermissionServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/permissions/PermissionServiceTest.java @@ -96,7 +96,7 @@ public void testGetPermissions() { } try { Map permissions = service - .getPermissions(c.apix(testNode.getNodeRef())); + .getPermissions(c.alfredApi(testNode.getNodeRef())); logger.debug(permissions.toString()); assertTrue(permissions.containsKey("Read")); assertTrue(permissions.containsKey("Write")); @@ -129,7 +129,7 @@ public void testGetPermissionsV2() { try { Map permissions = service - .getPermissionsFast(c.apix(testNode.getNodeRef())); + .getPermissionsFast(c.alfredApi(testNode.getNodeRef())); logger.debug(permissions.toString()); assertTrue(permissions.containsKey("Read")); assertTrue(permissions.containsKey("Write")); @@ -169,11 +169,11 @@ public void testSetPermissions() { accessSet.add(access); NodePermission nodePermission = new NodePermission(true, accessSet, null); - service.setNodePermissions(c.apix(testNode.getNodeRef()), nodePermission); + service.setNodePermissions(c.alfredApi(testNode.getNodeRef()), nodePermission); //check if the effect of setting the permissions is reached NodePermission nodePermission1 = service - .getNodePermissions(c.apix(testNode.getNodeRef())); + .getNodePermissions(c.alfredApi(testNode.getNodeRef())); assertEquals(nodePermission.isInheritFromParent(), nodePermission1.isInheritFromParent()); assertEquals(nodePermission.getOwnAccessList().size(), @@ -185,7 +185,7 @@ public void testSetPermissions() { assertNotEquals(initialAclId, llAlfrescoNodeService.getNodeAclId(testNode.getNodeRef())); //reset the nodes permissions - service.setNodePermissions(c.apix(testNode.getNodeRef()), + service.setNodePermissions(c.alfredApi(testNode.getNodeRef()), new NodePermission(true, new HashSet(), null)); //check if the aclId is set back to the initial one. diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/properties/PropertyServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/properties/PropertyServiceTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/properties/PropertyServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/properties/PropertyServiceTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/FtsNodeVisitorTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/QueryBuilderTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/QueryBuilderTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/QueryBuilderTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/QueryBuilderTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchNodeParsingTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchNodeParsingTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchNodeParsingTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchNodeParsingTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceFacetsTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceFacetsTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceFacetsTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceFacetsTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceTest.java similarity index 97% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceTest.java index 5c2d4779..33daad6e 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchServiceTest.java @@ -183,7 +183,8 @@ private void create1001TestDocs() throws InterruptedException { FileInfo testFolder = createTestFolder(mainTestFolder.getNodeRef(), "testFolderSetOf1001"); Map props = new HashMap<>(); props.put( - QName.createQName(APIX_TESTCM_NAMESPACE, APIX_TESTCM_PROP_SEARCHSERVICELIMITTEST_SHORTNAME), + QName.createQName(ALFRED_API_TESTCM_NAMESPACE, + ALFRED_API_TESTCM_PROP_SEARCHSERVICELIMITTEST_SHORTNAME), DESCRIPTION_SET_OF_1001 ); for (int i = 0; i < 1001; i++) { @@ -204,7 +205,7 @@ public void TestLimitedByMaxPermissionChecks_transactional() throws InterruptedE QueryBuilder builder = new QueryBuilder(); SearchSyntaxNode node = builder .property( - APIX_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED, + ALFRED_API_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED, DESCRIPTION_SET_OF_1001, true) .create(); @@ -224,7 +225,7 @@ public void TestLimitedByMaxPermissionChecks_transactional_if_possible() throws QueryBuilder builder = new QueryBuilder(); SearchSyntaxNode node = builder .property( - APIX_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED, + ALFRED_API_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED, DESCRIPTION_SET_OF_1001, true) .create(); @@ -244,7 +245,7 @@ public void TestLimitedByMaxPermissionChecks_eventual() throws InterruptedExcept QueryBuilder builder = new QueryBuilder(); SearchSyntaxNode node = builder .property( - APIX_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED, + ALFRED_API_TESTCM_PROP_SEARCHSERVICELIMITTEST_PREFIXED, DESCRIPTION_SET_OF_1001, //cant do exact searches against solr on custom props. false) diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchSyntaxPrinterTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchSyntaxPrinterTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchSyntaxPrinterTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/SearchSyntaxPrinterTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/TermHitHighlightingTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/TermHitHighlightingTest.java similarity index 97% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/TermHitHighlightingTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/TermHitHighlightingTest.java index cdf17e59..d8a4d82c 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/TermHitHighlightingTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/search/TermHitHighlightingTest.java @@ -52,8 +52,8 @@ public void createHighlightTestTxt() throws InterruptedException { FileInfo mainTestFolder = super.createMainTestFolder(getNodeAtPath("/app:company_home")); InputStream inputStream = new FileInputStream(txtFile); NodeRef target = nodeService.createNode( - super.c.apix(mainTestFolder.getNodeRef()), txtFile.getName(), - super.c.apix(ContentModel.TYPE_CONTENT)); + super.c.alfredApi(mainTestFolder.getNodeRef()), txtFile.getName(), + super.c.alfredApi(ContentModel.TYPE_CONTENT)); nodeService.setContent(target, inputStream, txtFile.getName()); return null; }, false, true); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/transaction/TransactionServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/transaction/TransactionServiceTest.java similarity index 94% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/transaction/TransactionServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/transaction/TransactionServiceTest.java index 6568d4f6..fe1858d3 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/transaction/TransactionServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/transaction/TransactionServiceTest.java @@ -38,7 +38,7 @@ public void TestTransactionService_NotransactionBaseScenario() { final TransactionServiceTest me = this; FileInfo testNode = me.createTestNode(mainTestFolder.getNodeRef(), "testnode"); assertEquals("testnode", testNode.getName()); - eu.xenit.alfred.api.data.NodeRef cNR = ffservice.getChildNodeRef(c.apix(mainTestFolder.getNodeRef()), "testnode"); + eu.xenit.alfred.api.data.NodeRef cNR = ffservice.getChildNodeRef(c.alfredApi(mainTestFolder.getNodeRef()), "testnode"); assertNotNull(cNR); } @@ -54,7 +54,7 @@ public FileInfo call() throws Exception { }, false, false); assertEquals("testnode", shouldExist.getName()); - eu.xenit.alfred.api.data.NodeRef cNR = ffservice.getChildNodeRef(c.apix(mainTestFolder.getNodeRef()), "testnode"); + eu.xenit.alfred.api.data.NodeRef cNR = ffservice.getChildNodeRef(c.alfredApi(mainTestFolder.getNodeRef()), "testnode"); assertNotNull(cNR); } } \ No newline at end of file diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/translation/TranslationServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/translation/TranslationServiceTest.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/translation/TranslationServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/translation/TranslationServiceTest.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/versionhistory/VersionHistoryServiceTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/versionhistory/VersionHistoryServiceTest.java similarity index 90% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/versionhistory/VersionHistoryServiceTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/versionhistory/VersionHistoryServiceTest.java index 17eaccc3..49befc00 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/versionhistory/VersionHistoryServiceTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/versionhistory/VersionHistoryServiceTest.java @@ -50,14 +50,14 @@ public void TestGetVersionHistory() { Map versionProperties = new HashMap<>(); //No version in the beginning - VersionHistory beforeVersioning = versionHistoryService.GetVersionHistory(c.apix(testNode)); + VersionHistory beforeVersioning = versionHistoryService.GetVersionHistory(c.alfredApi(testNode)); assertEquals(beforeVersioning.getVersionHistory().size(), 1); // changed from null to 1. //First a minor version versionProperties.put(VersionBaseModel.PROP_VERSION_TYPE, org.alfresco.service.cmr.version.VersionType.MINOR); org.alfresco.service.cmr.version.Version version = alfrizcoVersionHistoryService .createVersion(testNode, versionProperties); - VersionHistory initialVersioning = versionHistoryService.GetVersionHistory(c.apix(testNode)); + VersionHistory initialVersioning = versionHistoryService.GetVersionHistory(c.alfredApi(testNode)); assertNotEquals(initialVersioning, null); assertEquals(initialVersioning.getVersionHistory().size(), 2); // changed from 1 -> 2 @@ -71,7 +71,7 @@ public void TestGetVersionHistory() { versionProperties.put(VersionBaseModel.PROP_DESCRIPTION, "Test123"); org.alfresco.service.cmr.version.Version version2 = alfrizcoVersionHistoryService .createVersion(testNode, versionProperties); - VersionHistory secondVersioning = versionHistoryService.GetVersionHistory(c.apix(testNode)); + VersionHistory secondVersioning = versionHistoryService.GetVersionHistory(c.alfredApi(testNode)); assertNotEquals(secondVersioning, null); assertEquals(secondVersioning.getVersionHistory().size(), 3); // changed from 2 -> 3 Version secondVersion = secondVersioning.getVersionHistory().get(0); @@ -83,18 +83,18 @@ public void TestGetVersionHistory() { // Changed versionHistoryService.createVersion(...) to alfrizcoVersionHistoryService.createVersion(...) // Reason: Error - 06150065 Access Denied. The system is currently in read-only mode. // org.alfresco.service.transaction.ReadOnlyServerException: 06150065 Access Denied. The system is currently in read-only mode. - // NOTE: System has a valid license... Only a alfresco/apix Noderef conversion is called in the apix conversion + // NOTE: System has a valid license... Only a alfresco/alfredApi Noderef conversion is called in the alfredApi conversion public void TestCreateVersion() { Map versionProperties = new HashMap<>(); //No version in the beginning - VersionHistory beforeVersioning = versionHistoryService.GetVersionHistory(c.apix(testNode)); + VersionHistory beforeVersioning = versionHistoryService.GetVersionHistory(c.alfredApi(testNode)); assertEquals(beforeVersioning.getVersionHistory().size(), 1); versionProperties.put(VersionBaseModel.PROP_VERSION_TYPE, VersionType.MINOR); -// versionHistoryService.createVersion(c.apix(testNode), versionProperties); +// versionHistoryService.createVersion(c.alfredApi(testNode), versionProperties); alfrizcoVersionHistoryService.createVersion(testNode, versionProperties); - VersionHistory initialVersioning = versionHistoryService.GetVersionHistory(c.apix(testNode)); + VersionHistory initialVersioning = versionHistoryService.GetVersionHistory(c.alfredApi(testNode)); assertNotEquals(initialVersioning, null); assertEquals(2, initialVersioning.getVersionHistory().size()); // changed from 1 -> 2 Version firstVersion = initialVersioning.getVersionHistory().get(0); @@ -104,10 +104,10 @@ public void TestCreateVersion() { //Now a major version with comment versionProperties.put(VersionBaseModel.PROP_VERSION_TYPE, org.alfresco.service.cmr.version.VersionType.MAJOR); versionProperties.put(VersionBaseModel.PROP_DESCRIPTION, "Test123"); - // TODO - Apix createversion fails, see error above -// versionHistoryService.createVersion(c.apix(testNode), versionProperties); + // TODO - alfredApi createversion fails, see error above +// versionHistoryService.createVersion(c.alfredApi(testNode), versionProperties); alfrizcoVersionHistoryService.createVersion(testNode, versionProperties); - VersionHistory secondVersioning = versionHistoryService.GetVersionHistory(c.apix(testNode)); + VersionHistory secondVersioning = versionHistoryService.GetVersionHistory(c.alfredApi(testNode)); assertNotEquals(secondVersioning, null); assertEquals(secondVersioning.getVersionHistory().size(), 3); // 2 to 3?? Version secondVersion = secondVersioning.getVersionHistory().get(0); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/WorkflowServiceBaseTest.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/WorkflowServiceBaseTest.java similarity index 86% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/WorkflowServiceBaseTest.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/WorkflowServiceBaseTest.java index 245d78ee..a1b57149 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/WorkflowServiceBaseTest.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/WorkflowServiceBaseTest.java @@ -59,7 +59,7 @@ public abstract class WorkflowServiceBaseTest extends JavaApiBaseTest { protected final Map tasks = new HashMap<>(); private final List tempFiles = new ArrayList<>(); - protected IWorkflowService apixWorkflowService; + protected IWorkflowService alfredApiWorkflowService; protected MutableAuthenticationService authenticationService; protected NodeRef companyHomeNodeRef = null; @@ -69,7 +69,7 @@ public abstract class WorkflowServiceBaseTest extends JavaApiBaseTest { @Before public void initialiseBeansWorkflowServiceBaseTest() { - apixWorkflowService = getBean("eu.xenit.alfred.api.workflow.IWorkflowService", IWorkflowService.class); + alfredApiWorkflowService = getBean("eu.xenit.alfred.api.workflow.IWorkflowService", IWorkflowService.class); } protected void SetupLocal() { @@ -286,7 +286,7 @@ public WorkflowTask execute() { }, false, true); } - protected boolean apixTaskHasNoOwner(Task task) { + protected boolean alfredApiTaskHasNoOwner(Task task) { final String ownerQName = ContentModel.PROP_OWNER.toString(); Map releasedWFTaskProps = task.getProperties(); if (!releasedWFTaskProps.containsKey(ownerQName)) { @@ -294,18 +294,18 @@ protected boolean apixTaskHasNoOwner(Task task) { } String ownerValue = (String) releasedWFTaskProps.get(ownerQName); - boolean apixTaskHasNoOwner = null == ownerValue || ownerValue.isEmpty(); - logger.debug("apixTaskHasNoOwner: " + apixTaskHasNoOwner); - if (!apixTaskHasNoOwner) { - logger.debug("apixTaskHasNoOwner ownerValue is " + ownerValue); + boolean alfredApiTaskHasNoOwner = null == ownerValue || ownerValue.isEmpty(); + logger.debug("alfredApiTaskHasNoOwner: " + alfredApiTaskHasNoOwner); + if (!alfredApiTaskHasNoOwner) { + logger.debug("alfredApiTaskHasNoOwner ownerValue is " + ownerValue); } else if (null != ownerValue && ownerValue.isEmpty()) { - logger.debug("apixTaskHasNoOwner ownerValue is empty"); + logger.debug("alfredApiTaskHasNoOwner ownerValue is empty"); } - return apixTaskHasNoOwner; + return alfredApiTaskHasNoOwner; } protected boolean probeClaimAndRelease(String taskID, String currentUserName) { - boolean apixProbeClaimTask = apixProbeClaimTask(taskID, currentUserName); + boolean alfredApiProbeClaimTask = alfredApiProbeClaimTask(taskID, currentUserName); final String finalTaskID = taskID; WorkflowTask task = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @@ -314,17 +314,17 @@ public WorkflowTask execute() { return workflowService.getTaskById(finalTaskID); } }, false, true); - boolean apixProbeReleaseTask = apixProbeReleaseTask(task, currentUserName); + boolean alfredApiProbeReleaseTask = alfredApiProbeReleaseTask(task, currentUserName); boolean alfrescoProbeClaimTask = alfrescoProbeClaimTask(taskID, currentUserName); boolean alfrescoProbeReleaseTask = alfrescoProbeReleaseTask(taskID, currentUserName); - logger.debug("probeClaimAndRelease: apixProbeClaimTask: " + apixProbeClaimTask); - logger.debug("probeClaimAndRelease: apixProbeReleaseTask: " + apixProbeReleaseTask); + logger.debug("probeClaimAndRelease: alfredApiProbeClaimTask: " + alfredApiProbeClaimTask); + logger.debug("probeClaimAndRelease: alfredApiProbeReleaseTask: " + alfredApiProbeReleaseTask); logger.debug("probeClaimAndRelease: alfrescoProbeClaimTask: " + alfrescoProbeClaimTask); logger.debug("probeClaimAndRelease: alfrescoProbeReleaseTask: " + alfrescoProbeReleaseTask); - return apixProbeClaimTask - && apixProbeReleaseTask + return alfredApiProbeClaimTask + && alfredApiProbeReleaseTask && alfrescoProbeClaimTask && alfrescoProbeReleaseTask; } @@ -342,18 +342,18 @@ public WorkflowTask execute() { boolean notAlfrescoIsClaimable = !alfrescoIsClaimable(task, currentUserName); boolean alfrescoIsClaimable = alfrescoIsReleasable(task, currentUserName); - boolean notApixIsClaimable = !apixIsClaimable(taskID); - boolean apixIsReleasable = apixIsReleasable(taskID); + boolean notAlfredApiIsClaimable = !alfredApiIsClaimable(taskID); + boolean alfredApiIsReleasable = alfredApiIsReleasable(taskID); logger.debug("alfrescoProbeClaimTask: notAlfrescoIsClaimable: " + notAlfrescoIsClaimable); logger.debug("alfrescoProbeClaimTask: alfrescoIsClaimable: " + alfrescoIsClaimable); - logger.debug("alfrescoProbeClaimTask: notApixIsClaimable: " + notApixIsClaimable); - logger.debug("alfrescoProbeClaimTask: apixIsReleasable: " + apixIsReleasable); + logger.debug("alfrescoProbeClaimTask: notAlfredApiIsClaimable: " + notAlfredApiIsClaimable); + logger.debug("alfrescoProbeClaimTask: alfredApiIsReleasable: " + alfredApiIsReleasable); return notAlfrescoIsClaimable && alfrescoIsClaimable - && notApixIsClaimable - && apixIsReleasable; + && notAlfredApiIsClaimable + && alfredApiIsReleasable; } protected boolean alfrescoProbeReleaseTask(String taskID, String currentUserName) { @@ -417,8 +417,8 @@ public Boolean execute() { return alfrescoIsClaimable; } - protected boolean alfrescoIsClaimable(Task apixWfTask, String username) { - final String finalTaskID = apixWfTask.getId(); + protected boolean alfrescoIsClaimable(Task alfredApiWfTask, String username) { + final String finalTaskID = alfredApiWfTask.getId(); final WorkflowTask wfTask = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override @@ -440,60 +440,60 @@ public Boolean execute() { return alfrescoIsClaimable; } - protected boolean apixProbeClaimTask(String taskID, String currentUserName) { + protected boolean alfredApiProbeClaimTask(String taskID, String currentUserName) { final String finalTaskID = taskID; final String finalCurrentUserName = currentUserName; Task updatedTask = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.claimWorkflowTask(finalTaskID, finalCurrentUserName); + return alfredApiWorkflowService.claimWorkflowTask(finalTaskID, finalCurrentUserName); } }, false, true); - boolean notApixIsClaimable = !apixIsClaimable(updatedTask); + boolean notAlfredApiIsClaimable = !alfredApiIsClaimable(updatedTask); boolean notAlfrescoIsClaimable = !alfrescoIsClaimable(updatedTask, currentUserName); - boolean apixIsReleasable = apixIsReleasable(updatedTask); + boolean alfredApiIsReleasable = alfredApiIsReleasable(updatedTask); boolean alfrescoIsReleasable = alfrescoIsReleasable(updatedTask.getId(), currentUserName); - logger.debug("apixProbeClaimTask: notApixIsClaimable: " + notApixIsClaimable); - logger.debug("apixProbeClaimTask: notAlfrescoIsClaimable: " + notAlfrescoIsClaimable); - logger.debug("apixProbeClaimTask: apixIsReleasable: " + apixIsReleasable); - logger.debug("apixProbeClaimTask: alfrescoIsReleasable: " + alfrescoIsReleasable); + logger.debug("alfredApiProbeClaimTask: notAlfredApiIsClaimable: " + notAlfredApiIsClaimable); + logger.debug("alfredApiProbeClaimTask: notAlfrescoIsClaimable: " + notAlfrescoIsClaimable); + logger.debug("alfredApiProbeClaimTask: alfredApiIsReleasable: " + alfredApiIsReleasable); + logger.debug("alfredApiProbeClaimTask: alfrescoIsReleasable: " + alfrescoIsReleasable); - return notApixIsClaimable + return notAlfredApiIsClaimable && notAlfrescoIsClaimable - && apixIsReleasable + && alfredApiIsReleasable && alfrescoIsReleasable; } - protected boolean apixIsClaimable(String taskId) { + protected boolean alfredApiIsClaimable(String taskId) { final String finalTaskID = taskId; Task task = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.getTaskInfo(finalTaskID); + return alfredApiWorkflowService.getTaskInfo(finalTaskID); } }, false, true); - return apixIsClaimable(task); + return alfredApiIsClaimable(task); } - protected boolean apixIsClaimable(Task task) { + protected boolean alfredApiIsClaimable(Task task) { if (!task.getProperties().containsKey(ContentModel.PROP_OWNER.toString())) { Assert.fail(ContentModel.PROP_OWNER + " is not in the properties of the task."); } boolean isClaimable = (Boolean) task.getProperties().get(IWorkflowService.ALFRESCO_CLAIMABLE); - boolean apixTaskHasNoOwner = apixTaskHasNoOwner(task); + boolean alfredApiTaskHasNoOwner = alfredApiTaskHasNoOwner(task); - logger.debug("apixIsClaimable: isClaimable: " + isClaimable); - logger.debug("apixIsClaimable: apixTaskHasNoOwner: " + apixTaskHasNoOwner); + logger.debug("alfredApiIsClaimable: isClaimable: " + isClaimable); + logger.debug("alfredApiIsClaimable: alfredApiTaskHasNoOwner: " + alfredApiTaskHasNoOwner); - return apixTaskHasNoOwner && isClaimable; + return alfredApiTaskHasNoOwner && isClaimable; } - protected boolean apixProbeReleaseTask(String taskId, String currentUserName) { + protected boolean alfredApiProbeReleaseTask(String taskId, String currentUserName) { final String finalTaskId = taskId; WorkflowTask wfTask = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @@ -502,55 +502,54 @@ public WorkflowTask execute() { return workflowService.getTaskById(finalTaskId); } }, false, true); - return apixProbeReleaseTask(wfTask, currentUserName); + return alfredApiProbeReleaseTask(wfTask, currentUserName); } - protected boolean apixProbeReleaseTask(WorkflowTask wfTask, String currentUserName) { + protected boolean alfredApiProbeReleaseTask(WorkflowTask wfTask, String currentUserName) { final String wfTaskId = wfTask.getId(); Task releasedWFTask = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.releaseWorkflowTask(wfTaskId); + return alfredApiWorkflowService.releaseWorkflowTask(wfTaskId); } }, false, true); - boolean notApixIsReleasable = !apixIsReleasable(releasedWFTask); - boolean apixIsClaimable = apixIsClaimable(releasedWFTask); + boolean notAlfredApiIsReleasable = !alfredApiIsReleasable(releasedWFTask); + boolean alfredApiIsClaimable = alfredApiIsClaimable(releasedWFTask); boolean notAlfrescoIsReleasable = !alfrescoIsReleasable(wfTask, currentUserName); boolean alfrescoIsClaimable = alfrescoIsClaimable(wfTask, currentUserName); - logger.debug("apixProbeReleaseTask: notApixIsReleasable: " + notApixIsReleasable); - logger.debug("apixProbeReleaseTask: apixIsClaimable: " + apixIsClaimable); - logger.debug("apixProbeReleaseTask: notAlfrescoIsReleasable: " + notAlfrescoIsReleasable); - logger.debug("apixProbeReleaseTask: alfrescoIsClaimable: " + alfrescoIsClaimable); + logger.debug("alfredApiProbeReleaseTask: notAlfredApiIsReleasable: " + notAlfredApiIsReleasable); + logger.debug("alfredApiProbeReleaseTask: alfredApiIsClaimable: " + alfredApiIsClaimable); + logger.debug("alfredApiProbeReleaseTask: notAlfrescoIsReleasable: " + notAlfrescoIsReleasable); + logger.debug("alfredApiProbeReleaseTask: alfrescoIsClaimable: " + alfrescoIsClaimable); - return notApixIsReleasable - && apixIsClaimable + return notAlfredApiIsReleasable + && alfredApiIsClaimable && notAlfrescoIsReleasable && alfrescoIsClaimable; } - protected boolean apixIsReleasable(String taskId) { + protected boolean alfredApiIsReleasable(String taskId) { final String wfTaskId = taskId; Task task = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.getTaskInfo(wfTaskId); + return alfredApiWorkflowService.getTaskInfo(wfTaskId); } }, false, true); - return apixIsReleasable(task); + return alfredApiIsReleasable(task); } - protected boolean apixIsReleasable(Task task) { + protected boolean alfredApiIsReleasable(Task task) { if (!task.getProperties().containsKey(ContentModel.PROP_OWNER.toString())) { Assert.fail(ContentModel.PROP_OWNER + " is not in the properties of the task."); } boolean isReleasable = (Boolean) task.getProperties().get(IWorkflowService.ALFRESCO_RELEASABLE); - //boolean apixTaskHasNoOwner = apixTaskHasNoOwner(task); - logger.debug("apixIsReleasable: isReleasable: " + isReleasable); + logger.debug("alfredApiIsReleasable: isReleasable: " + isReleasable); return isReleasable; } @@ -577,7 +576,7 @@ protected boolean probeCancelWorkflow(WorkflowPath workflow) { .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Object execute() { - apixWorkflowService.cancelWorkflow(workflowId); + alfredApiWorkflowService.cancelWorkflow(workflowId); return null; } }, false, true); @@ -590,11 +589,11 @@ public WorkflowInstance execute() { } }, false, true); - boolean apixIsWorkflowCanceled_DoesNotExist = deletedWorkflow == null; + boolean alfredApiIsWorkflowCanceled_DoesNotExist = deletedWorkflow == null; logger.debug( - "probeCancelWorkflow: apixIsWorkflowCanceled_DoesNotExist: " + apixIsWorkflowCanceled_DoesNotExist); + "probeCancelWorkflow: alfredApiIsWorkflowCanceled_DoesNotExist: " + alfredApiIsWorkflowCanceled_DoesNotExist); - return apixIsWorkflowCanceled_DoesNotExist; + return alfredApiIsWorkflowCanceled_DoesNotExist; } @@ -619,7 +618,7 @@ public WorkflowInstance execute() { .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Workflow execute() { - return apixWorkflowService.getWorkflowInfo(workflowID); + return alfredApiWorkflowService.getWorkflowInfo(workflowID); } }, false, true); boolean hasAccessToWorkflowInstance = resultWf != null && workflowID.equals(resultWf.getId()); @@ -648,7 +647,7 @@ public WorkflowTask execute() { .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.getTaskInfo(finalTaskID); + return alfredApiWorkflowService.getTaskInfo(finalTaskID); } }, false, true); boolean hasAccessToWorkflowTask = resultWfTask != null && taskID.equals(resultWfTask.getId()); @@ -656,67 +655,67 @@ public Task execute() { return hasAccessToWorkflowTask; } - protected boolean apixProbeUpdateProperties(String taskId, WorkflowOrTaskChanges changes) { - logger.debug("apixProbeUpdateProperties: taskId: " + taskId); - logger.debug("apixProbeUpdateProperties: WorkflowOrTaskChanges: "); - PrintDebugMapOfString2String("apixProbeUpdateProperties input", changes.getPropertiesToSet()); + protected boolean alfredApiProbeUpdateProperties(String taskId, WorkflowOrTaskChanges changes) { + logger.debug("alfredApiProbeUpdateProperties: taskId: " + taskId); + logger.debug("alfredApiProbeUpdateProperties: WorkflowOrTaskChanges: "); + PrintDebugMapOfString2String("alfredApiProbeUpdateProperties input", changes.getPropertiesToSet()); final String finalTaskId = taskId; Map oldProperties = this.transactionHelper.doInTransaction( new RetryingTransactionHelper.RetryingTransactionCallback>() { @Override public Map execute() { - return apixWorkflowService.getTaskInfo(finalTaskId).getProperties(); + return alfredApiWorkflowService.getTaskInfo(finalTaskId).getProperties(); } }, false, true); - PrintDebugMapOfString2Serializable("apixProbeUpdateProperties oldProperties", oldProperties); + PrintDebugMapOfString2Serializable("alfredApiProbeUpdateProperties oldProperties", oldProperties); final WorkflowOrTaskChanges finalChanges = changes; Task updatedTask = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.updateTask(finalTaskId, finalChanges); + return alfredApiWorkflowService.updateTask(finalTaskId, finalChanges); } }, false, true); Map updatedProperties = updatedTask.getProperties(); - PrintDebugMapOfString2Serializable("apixProbeUpdateProperties updatedProperties", updatedProperties); + PrintDebugMapOfString2Serializable("alfredApiProbeUpdateProperties updatedProperties", updatedProperties); boolean resultAllPropertiesApplied = allPropertiesApplied(oldProperties, updatedProperties, new ArrayList(changes.getPropertiesToSet().keySet())); - logger.debug("apixProbeUpdateProperties: resultAllPropertiesApplied: " + resultAllPropertiesApplied); + logger.debug("alfredApiProbeUpdateProperties: resultAllPropertiesApplied: " + resultAllPropertiesApplied); return resultAllPropertiesApplied; } - protected boolean apixProbeUpdateProperties(String taskId, WorkflowOrTaskChanges changes, + protected boolean alfredApiProbeUpdateProperties(String taskId, WorkflowOrTaskChanges changes, Map unmodifiableProperties) { - logger.debug("apixProbeUpdateProperties: taskId: " + taskId); - logger.debug("apixProbeUpdateProperties: WorkflowOrTaskChanges: "); - PrintDebugMapOfString2String("apixProbeUpdateProperties input changes", changes.getPropertiesToSet()); - PrintDebugMapOfString2String("apixProbeUpdateProperties input unmodifiableProperties", unmodifiableProperties); + logger.debug("alfredApiProbeUpdateProperties: taskId: " + taskId); + logger.debug("alfredApiProbeUpdateProperties: WorkflowOrTaskChanges: "); + PrintDebugMapOfString2String("alfredApiProbeUpdateProperties input changes", changes.getPropertiesToSet()); + PrintDebugMapOfString2String("alfredApiProbeUpdateProperties input unmodifiableProperties", unmodifiableProperties); final String finalTaskId = taskId; Map oldProperties = this.transactionHelper.doInTransaction( new RetryingTransactionHelper.RetryingTransactionCallback>() { @Override public Map execute() { - return apixWorkflowService.getTaskInfo(finalTaskId).getProperties(); + return alfredApiWorkflowService.getTaskInfo(finalTaskId).getProperties(); } }, false, true); - PrintDebugMapOfString2Serializable("apixProbeUpdateProperties oldProperties", oldProperties); + PrintDebugMapOfString2Serializable("alfredApiProbeUpdateProperties oldProperties", oldProperties); final WorkflowOrTaskChanges finalChanges = changes; Task updatedTask = this.transactionHelper .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.updateTask(finalTaskId, finalChanges); + return alfredApiWorkflowService.updateTask(finalTaskId, finalChanges); } }, false, true); Map updatedProperties = updatedTask.getProperties(); - PrintDebugMapOfString2Serializable("apixProbeUpdateProperties updatedProperties", updatedProperties); + PrintDebugMapOfString2Serializable("alfredApiProbeUpdateProperties updatedProperties", updatedProperties); return mixedPropertiesApplied(oldProperties, updatedProperties, new ArrayList<>(unmodifiableProperties.keySet())); @@ -877,8 +876,8 @@ private void PrintDebugMapOfString2Serializable(String methodName, Map>() { @Override public Map execute() { - apixWorkflowService.endTask(finalTaskID, finalTransitionID); + alfredApiWorkflowService.endTask(finalTaskID, finalTransitionID); return null; } }, false, true); @@ -901,7 +900,7 @@ protected void initTransitionsAndTasks(String methodName, String sourceTaskID, .doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public Task execute() { - return apixWorkflowService.getTaskInfo(finalSourceTaskID); + return alfredApiWorkflowService.getTaskInfo(finalSourceTaskID); } }, false, true); logger.debug("initTransitionsAndTasks: task found: " + (task != null)); @@ -972,7 +971,7 @@ protected TaskOrWorkflowSearchResult getSearchResultTasks(TaskSearchQuery search new RetryingTransactionHelper.RetryingTransactionCallback() { @Override public TaskOrWorkflowSearchResult execute() { - return apixWorkflowService.searchTasks(finalSearchQuery); + return alfredApiWorkflowService.searchTasks(finalSearchQuery); } }, false, true); } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_BaseMethod_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_BaseMethod_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_BaseMethod_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_BaseMethod_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelMyWorkflow_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelMyWorkflow_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelMyWorkflow_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelMyWorkflow_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflowAsAdmin_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflowAsAdmin_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflowAsAdmin_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflowAsAdmin_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflow_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflow_Test.java similarity index 95% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflow_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflow_Test.java index 8979dfe4..0efd4b92 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflow_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_CancelSomebodyElseWorkflow_Test.java @@ -39,6 +39,6 @@ public void testCancelSomebodyElseWorkflow() { Assert.fail("Could not find pre-configured workflow for this test."); } - this.apixWorkflowService.cancelWorkflow(workflow.getId()); + this.alfredApiWorkflowService.cancelWorkflow(workflow.getId()); } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPoolAsAdmin_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPoolAsAdmin_Test.java similarity index 96% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPoolAsAdmin_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPoolAsAdmin_Test.java index a8f1250e..1c65e80e 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPoolAsAdmin_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPoolAsAdmin_Test.java @@ -44,7 +44,7 @@ public void testClaimOnOtherPoolAsAdmin() { Assert.fail("Could not find pre-configured task for this test."); } - assertTrue(apixProbeClaimTask(taskID, currentUserName)); + assertTrue(alfredApiProbeClaimTask(taskID, currentUserName)); assertTrue(alfrescoProbeClaimTask(taskID, currentUserName)); } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPool_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPool_Test.java similarity index 96% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPool_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPool_Test.java index 5082961d..54308ad3 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPool_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnOtherPool_Test.java @@ -50,7 +50,7 @@ public void testClaimOnOtherPool() { // Expected exception, swallow and proceed with the test } - this.apixWorkflowService.claimWorkflowTask(taskID, USER_FOREIGNER); + this.alfredApiWorkflowService.claimWorkflowTask(taskID, USER_FOREIGNER); } } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnReviewTask_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnReviewTask_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnReviewTask_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimOnReviewTask_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimReleaseWorkflowTaskOnPooledTask_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimReleaseWorkflowTaskOnPooledTask_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimReleaseWorkflowTaskOnPooledTask_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ClaimReleaseWorkflowTaskOnPooledTask_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessToAsAdmin_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessToAsAdmin_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessToAsAdmin_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessToAsAdmin_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessTo_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessTo_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessTo_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIDontHaveAccessTo_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIHaveAccessTo_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIHaveAccessTo_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIHaveAccessTo_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetTaskByIDIHaveAccessTo_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessToAsAdmin_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessToAsAdmin_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessToAsAdmin_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessToAsAdmin_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessTo_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessTo_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessTo_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIDontHaveAccessTo_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIHaveAccessTo_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIHaveAccessTo_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIHaveAccessTo_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_GetWorkflowByIDIHaveAccessTo_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasksAsAdmin_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasksAsAdmin_Test.java similarity index 94% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasksAsAdmin_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasksAsAdmin_Test.java index d16759d6..0f45ea66 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasksAsAdmin_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasksAsAdmin_Test.java @@ -47,9 +47,9 @@ public void testReleaseOnOtherClaimedTasksAsAdmin() { Assert.fail("Could not find pre-configured task for this test."); } - assertFalse(apixProbeReleaseTask(taskID, USER_ADMIN)); + assertFalse(alfredApiProbeReleaseTask(taskID, USER_ADMIN)); AuthenticationUtil.setFullyAuthenticatedUser(USER_A); - assertTrue(apixProbeClaimTask(taskID, USER_A)); + assertTrue(alfredApiProbeClaimTask(taskID, USER_A)); AuthenticationUtil.setFullyAuthenticatedUser(USER_ADMIN); assertFalse(alfrescoProbeReleaseTask(taskID, USER_ADMIN)); } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasks_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasks_Test.java similarity index 96% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasks_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasks_Test.java index ca9ac9b9..08c28a22 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasks_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_ReleaseOnOtherClaimedTasks_Test.java @@ -45,7 +45,7 @@ public void testReleaseOnOtherClaimedTasks() { Assert.fail("Could not find pre-configured task for this test."); } - assertFalse(apixProbeReleaseTask(taskID, USER_FOREIGNER)); + assertFalse(alfredApiProbeReleaseTask(taskID, USER_FOREIGNER)); assertFalse(alfrescoProbeClaimTask(taskID, USER_FOREIGNER)); } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextAllTasks_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextAllTasks_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextAllTasks_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextAllTasks_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyPooledTasks_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyPooledTasks_Test.java similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyPooledTasks_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyPooledTasks_Test.java diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyTasks_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyTasks_Test.java similarity index 97% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyTasks_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyTasks_Test.java index 321be104..2f9ef067 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyTasks_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_SearchContextMyTasks_Test.java @@ -48,7 +48,7 @@ public void testSearchContextMyTask() { List taskIds = this.tasks.get(testName); logger.debug("testSearchContextMyTask: taskIds.size(): " + taskIds.size()); - apixProbeClaimTask(taskIds.get(1), USER_A); + alfredApiProbeClaimTask(taskIds.get(1), USER_A); TaskSearchQuery searchQuery = createNewSearchQuery(TaskSearchQuery.QueryScope.MyTasks, 0, 5, Sorting.ASCENDING, IWorkflowService.ALFRESCO_STARTDATE); diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionMyTask_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionMyTask_Test.java similarity index 94% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionMyTask_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionMyTask_Test.java index 03061307..9d5cfbc9 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionMyTask_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionMyTask_Test.java @@ -48,9 +48,9 @@ public void testTransitioningMyTasks() { for (String transition : targetTasksMap.keySet()) { List taskIdToTransitions = targetTasksMap.get(transition); for (String taskIdToTransition : taskIdToTransitions) { - logger.debug("Claimed task: '" + taskIdToTransition + "' " + apixProbeClaimTask(taskIdToTransition, + logger.debug("Claimed task: '" + taskIdToTransition + "' " + alfredApiProbeClaimTask(taskIdToTransition, USER_A)); - probeApixTransitionTask(transition, taskIdToTransition); + probeAlfredApiTransitionTask(transition, taskIdToTransition); } } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTaskAsAdmin_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTaskAsAdmin_Test.java similarity index 94% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTaskAsAdmin_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTaskAsAdmin_Test.java index 4a3aa456..833fbcd0 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTaskAsAdmin_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTaskAsAdmin_Test.java @@ -50,9 +50,9 @@ public void testTransitioningSomeoneElseTasksAsAdmin() { for (String transition : targetTasksMap.keySet()) { List taskIdToTransitions = targetTasksMap.get(transition); for (String taskIdToTransition : taskIdToTransitions) { - logger.debug("Claimed task: '" + taskIdToTransition + "' " + apixProbeClaimTask(taskIdToTransition, + logger.debug("Claimed task: '" + taskIdToTransition + "' " + alfredApiProbeClaimTask(taskIdToTransition, USER_A)); - probeApixTransitionTask(transition, taskIdToTransition); + probeAlfredApiTransitionTask(transition, taskIdToTransition); } } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTask_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTask_Test.java similarity index 94% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTask_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTask_Test.java index 1a2da564..61726f8b 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTask_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_TransitionSomeoneElseTask_Test.java @@ -49,9 +49,9 @@ public void testTransitioningSomeoneElseTasks() { for (String transition : targetTasksMap.keySet()) { List taskIdToTransitions = targetTasksMap.get(transition); for (String taskIdToTransition : taskIdToTransitions) { - logger.debug("Claimed task: '" + taskIdToTransition + "' " + apixProbeClaimTask(taskIdToTransition, + logger.debug("Claimed task: '" + taskIdToTransition + "' " + alfredApiProbeClaimTask(taskIdToTransition, USER_A)); - apixWorkflowService.endTask(taskId, transition); + alfredApiWorkflowService.endTask(taskId, transition); } } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateEmpty_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateEmpty_Test.java similarity index 90% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateEmpty_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateEmpty_Test.java index bb44422a..3e46afd7 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateEmpty_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateEmpty_Test.java @@ -48,8 +48,8 @@ public void testUpdateEmpty() { } WorkflowOrTaskChanges emptyPropertiesPayload = new WorkflowOrTaskChanges(new HashMap()); - Map oldProperties = this.apixWorkflowService.getTaskInfo(taskID).getProperties(); - Task updatedTask = this.apixWorkflowService.updateTask(taskID, emptyPropertiesPayload); + Map oldProperties = this.alfredApiWorkflowService.getTaskInfo(taskID).getProperties(); + Task updatedTask = this.alfredApiWorkflowService.updateTask(taskID, emptyPropertiesPayload); assertFalse(noPropertiesApplied(oldProperties, updatedTask.getProperties())); } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateMixedProperties_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateMixedProperties_Test.java similarity index 93% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateMixedProperties_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateMixedProperties_Test.java index ac7e687a..8b0b5284 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateMixedProperties_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateMixedProperties_Test.java @@ -57,9 +57,9 @@ public void testUpdateMixedProperties() { Assert.fail("Could not find pre-configured task for this test."); } - assertTrue(apixProbeClaimTask(taskID, USER_A)); + assertTrue(alfredApiProbeClaimTask(taskID, USER_A)); WorkflowOrTaskChanges mixedPropertiesPayload = new WorkflowOrTaskChanges(sampleMixedProperties); - assertTrue(apixProbeUpdateProperties(taskID, mixedPropertiesPayload, unmodifiableProperties)); + assertTrue(alfredApiProbeUpdateProperties(taskID, mixedPropertiesPayload, unmodifiableProperties)); } } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateModifiableProperties_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateModifiableProperties_Test.java similarity index 93% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateModifiableProperties_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateModifiableProperties_Test.java index 1ed80d96..c714eb4b 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateModifiableProperties_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateModifiableProperties_Test.java @@ -54,9 +54,9 @@ public void testUpdateModifiableProperties() { Assert.fail("Could not find pre-configured task for this test."); } - assertTrue(apixProbeClaimTask(taskID, USER_A)); + assertTrue(alfredApiProbeClaimTask(taskID, USER_A)); WorkflowOrTaskChanges modifiablePropertiesPayload = new WorkflowOrTaskChanges(sampleModifiableProperties); - assertTrue(apixProbeUpdateProperties(taskID, modifiablePropertiesPayload)); + assertTrue(alfredApiProbeUpdateProperties(taskID, modifiablePropertiesPayload)); } } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateNull_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateNull_Test.java similarity index 90% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateNull_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateNull_Test.java index c43485dd..84f39bc7 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateNull_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateNull_Test.java @@ -45,8 +45,8 @@ public void testUpdateNull() { Assert.fail("Could not find pre-configured task for this test."); } - Map oldProperties = this.apixWorkflowService.getTaskInfo(taskID).getProperties(); - Task updatedTask = this.apixWorkflowService.updateTask(taskID, null); + Map oldProperties = this.alfredApiWorkflowService.getTaskInfo(taskID).getProperties(); + Task updatedTask = this.alfredApiWorkflowService.updateTask(taskID, null); assertFalse(noPropertiesApplied(oldProperties, updatedTask.getProperties())); } } diff --git a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateUnmodifiableProperties_Test.java b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateUnmodifiableProperties_Test.java similarity index 93% rename from apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateUnmodifiableProperties_Test.java rename to alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateUnmodifiableProperties_Test.java index b62de6cc..0d91252d 100644 --- a/apix-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateUnmodifiableProperties_Test.java +++ b/alfred-api-integrationtests-client/alfresco/src/main/java/eu/xenit/alfred/api/tests/workflow/methods/WorkflowService_UpdateUnmodifiableProperties_Test.java @@ -55,10 +55,10 @@ public void testUpdateUnmodifiableProperties() { Assert.fail("Could not find pre-configured task for this test."); } - assertTrue(apixProbeClaimTask(taskID, USER_A)); + assertTrue(alfredApiProbeClaimTask(taskID, USER_A)); WorkflowOrTaskChanges unmodifiablePropertiesPayload = new WorkflowOrTaskChanges( sampleUnmodifiableProperties); - assertFalse(apixProbeUpdateProperties(taskID, unmodifiablePropertiesPayload)); + assertFalse(alfredApiProbeUpdateProperties(taskID, unmodifiablePropertiesPayload)); } } } diff --git a/apix-integrationtests-client/alfresco/src/main/resources/cyrillic_message.msg b/alfred-api-integrationtests-client/alfresco/src/main/resources/cyrillic_message.msg similarity index 100% rename from apix-integrationtests-client/alfresco/src/main/resources/cyrillic_message.msg rename to alfred-api-integrationtests-client/alfresco/src/main/resources/cyrillic_message.msg diff --git a/apix-integrationtests-client/alfresco/src/main/resources/facet-forms-config.json b/alfred-api-integrationtests-client/alfresco/src/main/resources/facet-forms-config.json similarity index 84% rename from apix-integrationtests-client/alfresco/src/main/resources/facet-forms-config.json rename to alfred-api-integrationtests-client/alfresco/src/main/resources/facet-forms-config.json index 3ad7d216..7c8168d4 100644 --- a/apix-integrationtests-client/alfresco/src/main/resources/facet-forms-config.json +++ b/alfred-api-integrationtests-client/alfresco/src/main/resources/facet-forms-config.json @@ -34,10 +34,10 @@ "Id": "@{claims.model}administrator.__.u" }, { - "Id": "@{http://test.apix.xenit.eu/model/content}language.__.u" + "Id": "@{http://test.alfredapi.xenit.eu/model/content}language.__.u" }, { - "Id": "@{http://test.apix.xenit.eu/model/content}documentStatus.__.u" + "Id": "@{http://test.alfredapi.xenit.eu/model/content}documentStatus.__.u" } ] } diff --git a/apix-integrationtests-client/model-amp/README.md b/alfred-api-integrationtests-client/model-amp/README.md similarity index 100% rename from apix-integrationtests-client/model-amp/README.md rename to alfred-api-integrationtests-client/model-amp/README.md diff --git a/apix-integrationtests-client/model-amp/build.gradle b/alfred-api-integrationtests-client/model-amp/build.gradle similarity index 100% rename from apix-integrationtests-client/model-amp/build.gradle rename to alfred-api-integrationtests-client/model-amp/build.gradle diff --git a/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/messages/alfredapitest.properties b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/messages/alfredapitest.properties new file mode 100644 index 00000000..12412d46 --- /dev/null +++ b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/messages/alfredapitest.properties @@ -0,0 +1,5 @@ +listconstraint.alfredapitest_languageConstraint.English=English +listconstraint.alfredapitest_languageConstraint.French=French +listconstraint.alfredapitest_languageConstraint.Dutch=Dutch +listconstraint.alfredapitest_languageConstraint.German=German + diff --git a/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/messages/alfredapitest_nl.properties b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/messages/alfredapitest_nl.properties new file mode 100644 index 00000000..46a1f0d3 --- /dev/null +++ b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/messages/alfredapitest_nl.properties @@ -0,0 +1,5 @@ +listconstraint.alfredapitest_languageConstraint.English=Engels +listconstraint.alfredapitest_languageConstraint.French=Frans +listconstraint.alfredapitest_languageConstraint.Dutch=Nederlands +listconstraint.alfredapitest_languageConstraint.German=Duits + diff --git a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/model/apixtest-model.xml b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/model/alfred-api-test-model.xml similarity index 75% rename from apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/model/apixtest-model.xml rename to alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/model/alfred-api-test-model.xml index cfa542f2..56c2fec5 100644 --- a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/model/apixtest-model.xml +++ b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/model/alfred-api-test-model.xml @@ -2,8 +2,8 @@ - APIX integration tests Metadata Model + xmlns="http://www.alfresco.org/model/dictionary/1.0" name="alfredapitest:model"> + Alfred API integration tests Metadata Model gb 1 @@ -11,10 +11,10 @@ - + - + English @@ -24,7 +24,7 @@ - + Draft @@ -36,20 +36,20 @@ - + Type with aspects Type with aspects cm:content - apixtest:hasAuthor - apixtest:hasLanguage + alfredapitest:hasAuthor + alfredapitest:hasLanguage - + Type with mandatory properties cm:content - + documentStatus documentStatus d:text @@ -58,10 +58,10 @@ false - + - + sender sender d:text @@ -74,9 +74,9 @@ - + - + language language d:text @@ -86,14 +86,14 @@ false - + - + - + author author d:text @@ -104,9 +104,9 @@ - + - + d:text diff --git a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/module-context.xml b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/module-context.xml similarity index 77% rename from apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/module-context.xml rename to alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/module-context.xml index 774dc79a..988dcb6d 100644 --- a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/module-context.xml +++ b/alfred-api-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/alfred-api-integrationtests-model-amp/module-context.xml @@ -9,13 +9,13 @@ depends-on="dictionaryBootstrap"> - alfresco/module/apix-integrationtests-model-amp/model/apixtest-model.xml + alfresco/module/alfred-api-integrationtests-model-amp/model/alfred-api-test-model.xml - alfresco/module/apix-integrationtests-model-amp/messages/apixtest + alfresco/module/alfred-api-integrationtests-model-amp/messages/alfredapitest diff --git a/apix-integrationtests-server/build.gradle b/alfred-api-integrationtests-server/build.gradle similarity index 100% rename from apix-integrationtests-server/build.gradle rename to alfred-api-integrationtests-server/build.gradle diff --git a/apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/ApplicationContextSetter.java b/alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/ApplicationContextSetter.java similarity index 100% rename from apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/ApplicationContextSetter.java rename to alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/ApplicationContextSetter.java diff --git a/apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/Server.java b/alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/Server.java similarity index 100% rename from apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/Server.java rename to alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/server/Server.java diff --git a/apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/AlfrescoServerInfo.java b/alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/AlfrescoServerInfo.java similarity index 100% rename from apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/AlfrescoServerInfo.java rename to alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/AlfrescoServerInfo.java diff --git a/apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrAdminClient.java b/alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrAdminClient.java similarity index 100% rename from apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrAdminClient.java rename to alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrAdminClient.java diff --git a/apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelper.java b/alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelper.java similarity index 100% rename from apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelper.java rename to alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelper.java diff --git a/apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelperImpl.java b/alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelperImpl.java similarity index 100% rename from apix-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelperImpl.java rename to alfred-api-integrationtests-server/src/main/java/eu/xenit/alfred/api/util/SolrTestHelperImpl.java diff --git a/apix-integrationtests-server/src/main/resources/alfresco/module/alfred-api/context/service-context.xml b/alfred-api-integrationtests-server/src/main/resources/alfresco/module/alfred-api/context/service-context.xml similarity index 100% rename from apix-integrationtests-server/src/main/resources/alfresco/module/alfred-api/context/service-context.xml rename to alfred-api-integrationtests-server/src/main/resources/alfresco/module/alfred-api/context/service-context.xml diff --git a/apix-integrationtests-server/src/main/resources/alfresco/module/alfred-api/module-context.xml b/alfred-api-integrationtests-server/src/main/resources/alfresco/module/alfred-api/module-context.xml similarity index 100% rename from apix-integrationtests-server/src/main/resources/alfresco/module/alfred-api/module-context.xml rename to alfred-api-integrationtests-server/src/main/resources/alfresco/module/alfred-api/module-context.xml diff --git a/apix-integrationtests-server/src/test/java/eu/xenit/alfred/api/server/AlfrescoApplicationContextIT.java b/alfred-api-integrationtests-server/src/test/java/eu/xenit/alfred/api/server/AlfrescoApplicationContextIT.java similarity index 100% rename from apix-integrationtests-server/src/test/java/eu/xenit/alfred/api/server/AlfrescoApplicationContextIT.java rename to alfred-api-integrationtests-server/src/test/java/eu/xenit/alfred/api/server/AlfrescoApplicationContextIT.java diff --git a/apix-interface/build.gradle b/alfred-api-interface/build.gradle similarity index 100% rename from apix-interface/build.gradle rename to alfred-api-interface/build.gradle diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/WIP/IWIPService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/WIP/IWIPService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/WIP/IWIPService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/WIP/IWIPService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/categories/Category.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/categories/Category.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/categories/Category.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/categories/Category.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/categories/ICategoryService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/categories/ICategoryService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/categories/ICategoryService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/categories/ICategoryService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/comments/Comment.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/comments/Comment.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/comments/Comment.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/comments/Comment.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/comments/Conversation.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/comments/Conversation.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/comments/Conversation.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/comments/Conversation.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/comments/ICommentService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/comments/ICommentService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/comments/ICommentService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/comments/ICommentService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFile.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFile.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFile.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFile.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileComparator.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileComparator.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileComparator.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileComparator.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileFlags.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileFlags.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileFlags.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationFileFlags.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/ConfigurationService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/configuration/Configurations.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/Configurations.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/configuration/Configurations.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/configuration/Configurations.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/content/IContentService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/content/IContentService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/content/IContentService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/content/IContentService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/data/ContentData.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/ContentData.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/data/ContentData.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/ContentData.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/data/ContentInputStream.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/ContentInputStream.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/data/ContentInputStream.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/ContentInputStream.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/data/NodeRef.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/NodeRef.java similarity index 98% rename from apix-interface/src/main/java/eu/xenit/alfred/api/data/NodeRef.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/NodeRef.java index 659a9005..9edeb834 100644 --- a/apix-interface/src/main/java/eu/xenit/alfred/api/data/NodeRef.java +++ b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/NodeRef.java @@ -44,7 +44,7 @@ public String toString() { return getValue(); } - public String GetApixUrl() { + public String GetAlfredApiUrl() { return getStoreRefProtocol() + "/" + getStoreRefId() + "/" + getGuid(); } diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/data/Path.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/Path.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/data/Path.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/Path.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/data/QName.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/QName.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/data/QName.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/QName.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/data/StoreRef.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/StoreRef.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/data/StoreRef.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/data/StoreRef.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/IDictionaryService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/IDictionaryService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/IDictionaryService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/IDictionaryService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/AspectDefinition.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/AspectDefinition.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/AspectDefinition.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/AspectDefinition.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/Aspects.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/Aspects.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/Aspects.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/Aspects.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/IAspectService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/IAspectService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/IAspectService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/aspects/IAspectService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespace.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespace.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespace.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespace.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespaces.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespaces.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespaces.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/namespaces/Namespaces.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/properties/IPropertyService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/properties/IPropertyService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/properties/IPropertyService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/properties/IPropertyService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/ITypeService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/ITypeService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/ITypeService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/ITypeService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/TypeDefinition.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/TypeDefinition.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/TypeDefinition.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/TypeDefinition.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/Types.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/Types.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/Types.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/dictionary/types/Types.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/exceptions/FileExistsException.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/exceptions/FileExistsException.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/exceptions/FileExistsException.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/exceptions/FileExistsException.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/filefolder/IFileFolderService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/filefolder/IFileFolderService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/filefolder/IFileFolderService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/filefolder/IFileFolderService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/filefolder/NodePath.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/filefolder/NodePath.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/filefolder/NodePath.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/filefolder/NodePath.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/groups/Group.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/groups/Group.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/groups/Group.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/groups/Group.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/node/ChildParentAssociation.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/ChildParentAssociation.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/node/ChildParentAssociation.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/ChildParentAssociation.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/node/INodeService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/INodeService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/node/INodeService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/INodeService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/node/MetadataChanges.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/MetadataChanges.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/node/MetadataChanges.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/MetadataChanges.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociation.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociation.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociation.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociation.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociations.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociations.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociations.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/NodeAssociations.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/node/NodeMetadata.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/NodeMetadata.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/node/NodeMetadata.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/node/NodeMetadata.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/people/AuthorityType.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/people/AuthorityType.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/people/AuthorityType.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/people/AuthorityType.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/people/IPeopleService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/people/IPeopleService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/people/IPeopleService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/people/IPeopleService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/people/Person.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/people/Person.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/people/Person.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/people/Person.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/permissions/IPermissionService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/permissions/IPermissionService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/permissions/IPermissionService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/permissions/IPermissionService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/permissions/NodePermission.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/permissions/NodePermission.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/permissions/NodePermission.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/permissions/NodePermission.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/permissions/PermissionValue.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/permissions/PermissionValue.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/permissions/PermissionValue.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/permissions/PermissionValue.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/properties/IPropertyService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/IPropertyService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/properties/IPropertyService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/IPropertyService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/properties/Properties.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/Properties.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/properties/Properties.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/Properties.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyConstraintDefinition.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyConstraintDefinition.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyConstraintDefinition.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyConstraintDefinition.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyDefinition.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyDefinition.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyDefinition.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyDefinition.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyFacetable.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyFacetable.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyFacetable.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyFacetable.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyIndexOptions.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyIndexOptions.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyIndexOptions.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyIndexOptions.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyTokenised.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyTokenised.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyTokenised.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/properties/PropertyTokenised.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/FacetSearchResult.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/FacetSearchResult.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/FacetSearchResult.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/FacetSearchResult.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/Highlights.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/Highlights.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/Highlights.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/Highlights.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/ISearchService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/ISearchService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/ISearchService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/ISearchService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/QueryBuilder.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/QueryBuilder.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/QueryBuilder.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/QueryBuilder.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/SearchQuery.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/SearchQuery.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/SearchQuery.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/SearchQuery.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryConsistency.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryConsistency.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryConsistency.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryConsistency.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryResult.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryResult.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryResult.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/SearchQueryResult.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/CustomSubtypeResolver.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/CustomSubtypeResolver.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/CustomSubtypeResolver.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/CustomSubtypeResolver.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/IJsonTyped.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/IJsonTyped.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/IJsonTyped.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/IJsonTyped.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/InvertSearchNodeDeserializer.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/InvertSearchNodeDeserializer.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/InvertSearchNodeDeserializer.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/InvertSearchNodeDeserializer.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/OperatorSearchNodeDeserializer.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/OperatorSearchNodeDeserializer.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/OperatorSearchNodeDeserializer.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/OperatorSearchNodeDeserializer.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeDeserializer.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeDeserializer.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeDeserializer.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeDeserializer.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeJsonParser.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeJsonParser.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeJsonParser.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeJsonParser.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeTypeDeserializer.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeTypeDeserializer.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeTypeDeserializer.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/SearchNodeTypeDeserializer.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/json/TypeResolver.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/TypeResolver.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/json/TypeResolver.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/json/TypeResolver.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/BaseValueNode.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/BaseValueNode.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/BaseValueNode.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/BaseValueNode.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/InvertSearchNode.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/InvertSearchNode.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/InvertSearchNode.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/InvertSearchNode.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/OperatorSearchNode.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/OperatorSearchNode.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/OperatorSearchNode.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/OperatorSearchNode.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/PropertySearchNode.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/PropertySearchNode.java similarity index 97% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/PropertySearchNode.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/PropertySearchNode.java index c3ba702a..fd03ffba 100644 --- a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/PropertySearchNode.java +++ b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/PropertySearchNode.java @@ -41,7 +41,7 @@ public String getName() { public void setName(String name) { // Solr queries where the property name contains any of the characters in the regex below trigger an error - // in solr. This error is propagated through alfresco and apix. To prevent this, we escape the characters + // in solr. This error is propagated through alfresco and alfredApi. To prevent this, we escape the characters // before the terms enter solr. this.name = escapeName(name); } diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/RangeValue.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/RangeValue.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/RangeValue.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/RangeValue.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/SearchSyntaxNode.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/SearchSyntaxNode.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/SearchSyntaxNode.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/SearchSyntaxNode.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/TermSearchNode.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/TermSearchNode.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/nodes/TermSearchNode.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/nodes/TermSearchNode.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/visitors/BaseSearchSyntaxNodeVisitor.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/visitors/BaseSearchSyntaxNodeVisitor.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/visitors/BaseSearchSyntaxNodeVisitor.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/visitors/BaseSearchSyntaxNodeVisitor.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/visitors/ISearchSyntaxVisitor.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/visitors/ISearchSyntaxVisitor.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/visitors/ISearchSyntaxVisitor.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/visitors/ISearchSyntaxVisitor.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/search/visitors/SearchSyntaxPrinter.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/visitors/SearchSyntaxPrinter.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/search/visitors/SearchSyntaxPrinter.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/search/visitors/SearchSyntaxPrinter.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/sites/ISite.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/sites/ISite.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/sites/ISite.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/sites/ISite.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/sites/ISiteService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/sites/ISiteService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/sites/ISiteService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/sites/ISiteService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/transaction/ITransactionService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/transaction/ITransactionService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/transaction/ITransactionService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/transaction/ITransactionService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/translation/ITranslationService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/ITranslationService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/translation/ITranslationService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/ITranslationService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/translation/PropertyTranslationValue.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/PropertyTranslationValue.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/translation/PropertyTranslationValue.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/PropertyTranslationValue.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/translation/TranslationValue.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/TranslationValue.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/translation/TranslationValue.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/TranslationValue.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/translation/Translations.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/Translations.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/translation/Translations.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/translation/Translations.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/utils/PrintUtils.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/utils/PrintUtils.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/utils/PrintUtils.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/utils/PrintUtils.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/utils/SerializableUtils.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/utils/SerializableUtils.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/utils/SerializableUtils.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/utils/SerializableUtils.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/utils/StringUtils.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/utils/StringUtils.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/utils/StringUtils.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/utils/StringUtils.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/version/IVersionService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/version/IVersionService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/version/IVersionService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/version/IVersionService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/version/VersionDescription.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/version/VersionDescription.java similarity index 97% rename from apix-interface/src/main/java/eu/xenit/alfred/api/version/VersionDescription.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/version/VersionDescription.java index dd7176b1..3e69c660 100644 --- a/apix-interface/src/main/java/eu/xenit/alfred/api/version/VersionDescription.java +++ b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/version/VersionDescription.java @@ -4,7 +4,7 @@ import java.util.regex.Pattern; /** - * Describes the apix implementation version + * Describes the alfredApi implementation version */ public class VersionDescription { diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/versionhistory/IVersionHistoryService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/versionhistory/IVersionHistoryService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/versionhistory/IVersionHistoryService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/versionhistory/IVersionHistoryService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/versionhistory/Version.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/versionhistory/Version.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/versionhistory/Version.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/versionhistory/Version.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/versionhistory/VersionHistory.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/versionhistory/VersionHistory.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/versionhistory/VersionHistory.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/versionhistory/VersionHistory.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/web/IWebUtils.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/web/IWebUtils.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/web/IWebUtils.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/web/IWebUtils.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/IWorkflowService.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/IWorkflowService.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/IWorkflowService.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/IWorkflowService.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/ITaskOrWorkflow.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/ITaskOrWorkflow.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/ITaskOrWorkflow.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/ITaskOrWorkflow.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Task.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Task.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Task.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Task.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskDefinition.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskDefinition.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskDefinition.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskDefinition.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskTransition.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskTransition.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskTransition.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/TaskTransition.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Workflow.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Workflow.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Workflow.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/Workflow.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowChanges.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowChanges.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowChanges.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowChanges.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowConstants.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowConstants.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowConstants.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowConstants.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinition.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinition.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinition.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinition.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinitionList.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinitionList.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinitionList.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowDefinitionList.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowOrTaskChanges.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowOrTaskChanges.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowOrTaskChanges.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/model/WorkflowOrTaskChanges.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/AuthorityFilter.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/AuthorityFilter.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/AuthorityFilter.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/AuthorityFilter.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/DateRangeFilter.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/DateRangeFilter.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/DateRangeFilter.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/DateRangeFilter.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facet.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facet.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facet.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facet.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/FacetValue.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/FacetValue.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/FacetValue.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/FacetValue.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facets.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facets.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facets.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Facets.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/IQueryFilter.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/IQueryFilter.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/IQueryFilter.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/IQueryFilter.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Paging.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Paging.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Paging.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Paging.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/PropertyFilter.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/PropertyFilter.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/PropertyFilter.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/PropertyFilter.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/SearchQuery.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/SearchQuery.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/SearchQuery.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/SearchQuery.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Sorting.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Sorting.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Sorting.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/Sorting.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskOrWorkflowSearchResult.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskOrWorkflowSearchResult.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskOrWorkflowSearchResult.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskOrWorkflowSearchResult.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskSearchQuery.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskSearchQuery.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskSearchQuery.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/TaskSearchQuery.java diff --git a/apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/WorkflowSearchQuery.java b/alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/WorkflowSearchQuery.java similarity index 100% rename from apix-interface/src/main/java/eu/xenit/alfred/api/workflow/search/WorkflowSearchQuery.java rename to alfred-api-interface/src/main/java/eu/xenit/alfred/api/workflow/search/WorkflowSearchQuery.java diff --git a/apix-interface/src/test/java/eu/xenit/alfred/api/data/NodeRefTest.java b/alfred-api-interface/src/test/java/eu/xenit/alfred/api/data/NodeRefTest.java similarity index 100% rename from apix-interface/src/test/java/eu/xenit/alfred/api/data/NodeRefTest.java rename to alfred-api-interface/src/test/java/eu/xenit/alfred/api/data/NodeRefTest.java diff --git a/apix-interface/src/test/java/eu/xenit/alfred/api/data/StoreRefTest.java b/alfred-api-interface/src/test/java/eu/xenit/alfred/api/data/StoreRefTest.java similarity index 100% rename from apix-interface/src/test/java/eu/xenit/alfred/api/data/StoreRefTest.java rename to alfred-api-interface/src/test/java/eu/xenit/alfred/api/data/StoreRefTest.java diff --git a/apix-interface/src/test/java/eu/xenit/alfred/api/search/nodes/PropertySearchNodeTest.java b/alfred-api-interface/src/test/java/eu/xenit/alfred/api/search/nodes/PropertySearchNodeTest.java similarity index 100% rename from apix-interface/src/test/java/eu/xenit/alfred/api/search/nodes/PropertySearchNodeTest.java rename to alfred-api-interface/src/test/java/eu/xenit/alfred/api/search/nodes/PropertySearchNodeTest.java diff --git a/apix-rest/build.gradle b/alfred-api-rest/build.gradle similarity index 88% rename from apix-rest/build.gradle rename to alfred-api-rest/build.gradle index cc7610b5..fbee6c51 100644 --- a/apix-rest/build.gradle +++ b/alfred-api-rest/build.gradle @@ -11,7 +11,7 @@ dependencies { implementation platform("org.alfresco:acs-community-packaging:${alfresco_version}") // Alfresco dependency should be removed in the future alfrescoProvided("org.alfresco:alfresco-repository") - alfrescoProvided project(':apix-interface') + alfrescoProvided project(':alfred-api-interface') alfrescoProvided('org.alfresco:alfresco-remote-api') alfrescoProvided "com.gradecak.alfresco-mvc:alfresco-mvc-rest:${mvc}" @@ -21,8 +21,8 @@ dependencies { // https://github.com/FasterXML/jackson-modules-base/discussions/239 implementation group: 'javax.xml.bind', name: 'jaxb-api', version: '2.3.1' - testImplementation(project(':apix-interface')) { transitive = false } - testImplementation project(':apix-impl') + testImplementation(project(':alfred-api-interface')) { transitive = false } + testImplementation project(':alfred-api-impl') testImplementation platform("org.alfresco:acs-community-packaging:${alfresco_version}") testImplementation 'org.springframework:spring-core' testImplementation 'org.springframework:spring-test' diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/AlfredApiRestServletContext.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/AlfredApiRestServletContext.java similarity index 91% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/AlfredApiRestServletContext.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/AlfredApiRestServletContext.java index a6ba2872..43c81ca6 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/AlfredApiRestServletContext.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/AlfredApiRestServletContext.java @@ -6,10 +6,10 @@ import com.fasterxml.jackson.databind.ObjectMapper; import com.gradecak.alfresco.mvc.annotation.EnableAlfrescoMvcAop; import com.gradecak.alfresco.mvc.rest.config.DefaultAlfrescoMvcServletContextConfiguration; -import eu.xenit.alfred.api.rest.jackson.Jackson2ApixNodeRefDeserializer; -import eu.xenit.alfred.api.rest.jackson.Jackson2ApixNodeRefSerializer; -import eu.xenit.alfred.api.rest.jackson.Jackson2ApixQnameDeserializer; -import eu.xenit.alfred.api.rest.jackson.Jackson2ApixQnameSerializer; +import eu.xenit.alfred.api.rest.jackson.Jackson2AlfredApiNodeRefDeserializer; +import eu.xenit.alfred.api.rest.jackson.Jackson2AlfredApiNodeRefSerializer; +import eu.xenit.alfred.api.rest.jackson.Jackson2AlfredApiQnameDeserializer; +import eu.xenit.alfred.api.rest.jackson.Jackson2AlfredApiQnameSerializer; import eu.xenit.alfred.api.rest.staging.workflow.WorkflowWebscript; import eu.xenit.alfred.api.rest.v0.categories.ClassificationGetWebscript; import eu.xenit.alfred.api.rest.v0.dictionary.DictionaryServiceChecksumWebscript; @@ -96,16 +96,16 @@ public AlfredApiRestServletContext(RestJsonModule alfrescoRestJsonModule, Namesp @Override protected List> customJsonDeserializers() { return Arrays.asList( - new Jackson2ApixNodeRefDeserializer(), - new Jackson2ApixQnameDeserializer() + new Jackson2AlfredApiNodeRefDeserializer(), + new Jackson2AlfredApiQnameDeserializer() ); } @Override protected List> customJsonSerilizers() { return Arrays.asList( - new Jackson2ApixNodeRefSerializer(), - new Jackson2ApixQnameSerializer() + new Jackson2AlfredApiNodeRefSerializer(), + new Jackson2AlfredApiQnameSerializer() ); } diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/SpringConfig.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/SpringConfig.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/SpringConfig.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/SpringConfig.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixAbstractSerializer.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiAbstractSerializer.java similarity index 79% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixAbstractSerializer.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiAbstractSerializer.java index 14c11b22..3bea3205 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixAbstractSerializer.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiAbstractSerializer.java @@ -7,12 +7,12 @@ import java.io.IOException; import java.io.Serializable; -public abstract class Jackson2ApixAbstractSerializer extends StdSerializer { +public abstract class Jackson2AlfredApiAbstractSerializer extends StdSerializer { private static final long serialVersionUID = 1L; private final Class supportedClass; - protected Jackson2ApixAbstractSerializer(Class clazz) { + protected Jackson2AlfredApiAbstractSerializer(Class clazz) { super(clazz); this.supportedClass = clazz; } diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixNodeRefDeserializer.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiNodeRefDeserializer.java similarity index 85% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixNodeRefDeserializer.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiNodeRefDeserializer.java index 796824cf..2f199a35 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixNodeRefDeserializer.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiNodeRefDeserializer.java @@ -8,7 +8,7 @@ import java.io.IOException; -public class Jackson2ApixNodeRefDeserializer extends JsonDeserializer implements Converter { +public class Jackson2AlfredApiNodeRefDeserializer extends JsonDeserializer implements Converter { @Override public Class handledType() { diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixNodeRefSerializer.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiNodeRefSerializer.java similarity index 53% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixNodeRefSerializer.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiNodeRefSerializer.java index ad8c3281..d9ab9c6e 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixNodeRefSerializer.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiNodeRefSerializer.java @@ -2,11 +2,11 @@ import eu.xenit.alfred.api.data.NodeRef; -public class Jackson2ApixNodeRefSerializer extends Jackson2ApixAbstractSerializer { +public class Jackson2AlfredApiNodeRefSerializer extends Jackson2AlfredApiAbstractSerializer { private static final long serialVersionUID = 1L; - public Jackson2ApixNodeRefSerializer() { + public Jackson2AlfredApiNodeRefSerializer() { super(NodeRef.class); } } diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixQnameDeserializer.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiQnameDeserializer.java similarity index 85% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixQnameDeserializer.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiQnameDeserializer.java index 3f8bdf4f..9c02738c 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixQnameDeserializer.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiQnameDeserializer.java @@ -8,7 +8,7 @@ import java.io.IOException; -public class Jackson2ApixQnameDeserializer extends JsonDeserializer implements Converter { +public class Jackson2AlfredApiQnameDeserializer extends JsonDeserializer implements Converter { @Override public Class handledType() { diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixQnameSerializer.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiQnameSerializer.java similarity index 54% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixQnameSerializer.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiQnameSerializer.java index cfc066ab..7ad547b7 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2ApixQnameSerializer.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/jackson/Jackson2AlfredApiQnameSerializer.java @@ -2,11 +2,11 @@ import eu.xenit.alfred.api.data.QName; -public class Jackson2ApixQnameSerializer extends Jackson2ApixAbstractSerializer { +public class Jackson2AlfredApiQnameSerializer extends Jackson2AlfredApiAbstractSerializer { private static final long serialVersionUID = 1L; - public Jackson2ApixQnameSerializer() { + public Jackson2AlfredApiQnameSerializer() { super(QName.class); } } diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowClaimsBody.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowClaimsBody.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowClaimsBody.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowClaimsBody.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowReleaseBody.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowReleaseBody.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowReleaseBody.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowReleaseBody.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowWebscript.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/staging/workflow/WorkflowWebscript.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/categories/ClassificationGetWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/categories/ClassificationGetWebscript.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/categories/ClassificationGetWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/categories/ClassificationGetWebscript.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/dictionary/DictionaryServiceChecksumWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/dictionary/DictionaryServiceChecksumWebscript.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/dictionary/DictionaryServiceChecksumWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/dictionary/DictionaryServiceChecksumWebscript.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataBulkWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataBulkWebscript.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataBulkWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataBulkWebscript.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataChangesV0.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataChangesV0.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataChangesV0.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataChangesV0.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataGetWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataGetWebscript.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataGetWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataGetWebscript.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataPostWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataPostWebscript.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataPostWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/MetadataPostWebscript.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/NodeMetadataV0.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/NodeMetadataV0.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/NodeMetadataV0.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/NodeMetadataV0.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/TranslationV0.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/TranslationV0.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/TranslationV0.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/metadata/TranslationV0.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchQueryV0.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchQueryV0.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchQueryV0.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchQueryV0.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchWebScript0.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchWebScript0.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchWebScript0.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v0/search/SearchWebScript0.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/ApixV1Webscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/AlfredApiV1Webscript.java similarity index 98% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/ApixV1Webscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/AlfredApiV1Webscript.java index 753204da..717dadb4 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/ApixV1Webscript.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/AlfredApiV1Webscript.java @@ -21,9 +21,9 @@ import org.slf4j.LoggerFactory; import org.springframework.http.ResponseEntity; -public class ApixV1Webscript { +public class AlfredApiV1Webscript { - private static final Logger logger = LoggerFactory.getLogger(ApixV1Webscript.class); + private static final Logger logger = LoggerFactory.getLogger(AlfredApiV1Webscript.class); protected ResponseEntity writeJsonResponse(T object) { return ResponseEntity.ok(object); diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/ExceptionObject.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/ExceptionObject.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/ExceptionObject.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/ExceptionObject.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/GeneralWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/GeneralWebscript.java similarity index 87% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/GeneralWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/GeneralWebscript.java index 7ff7ade7..ab4ae82f 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/GeneralWebscript.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/GeneralWebscript.java @@ -11,7 +11,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class GeneralWebscript extends ApixV1Webscript { +public class GeneralWebscript extends AlfredApiV1Webscript { private final IVersionService versionService; @@ -21,7 +21,7 @@ public GeneralWebscript(IVersionService versionService) { @AlfrescoTransaction(readOnly = true) @GetMapping(value = "/v1/version") - public ResponseEntity getApixVersion() { + public ResponseEntity getAlfredApiVersion() { return writeJsonResponse(versionService.getVersionDescription()); } } \ No newline at end of file diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/RestV1Config.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/RestV1Config.java similarity index 80% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/RestV1Config.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/RestV1Config.java index d0a4b115..2f6f9574 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/RestV1Config.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/RestV1Config.java @@ -6,6 +6,6 @@ public class RestV1Config { public static final String BaseUrl = "/apix/v1"; - public static final String ApixUrl = "/apix"; + public static final String AlfredApiUrl = "/apix"; public static final String Family = "Api-X v1"; } diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkSubResult.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkSubResult.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkSubResult.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkSubResult.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkWebscript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkWebscript1.java similarity index 98% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkWebscript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkWebscript1.java index a5d92275..80240c1a 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkWebscript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/BulkWebscript1.java @@ -4,7 +4,7 @@ import com.fasterxml.jackson.databind.ObjectMapper; import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; import com.gradecak.alfresco.mvc.webscript.DispatcherWebscript; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import eu.xenit.alfred.api.rest.v1.bulk.request.BulkHttpServletRequest; import eu.xenit.alfred.api.rest.v1.bulk.request.BulkRequest; import eu.xenit.alfred.api.rest.v1.bulk.request.IntermediateRequest; @@ -32,7 +32,7 @@ @RestController -public class BulkWebscript1 extends ApixV1Webscript { +public class BulkWebscript1 extends AlfredApiV1Webscript { private static final Logger logger = LoggerFactory.getLogger(BulkWebscript1.class); diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkHttpServletRequest.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkHttpServletRequest.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkHttpServletRequest.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkHttpServletRequest.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkRequest.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkRequest.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkRequest.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/BulkRequest.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateContent.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateContent.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateContent.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateContent.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateRequest.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateRequest.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateRequest.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/request/IntermediateRequest.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/DelegatingServletOutputStream.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/DelegatingServletOutputStream.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/DelegatingServletOutputStream.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/DelegatingServletOutputStream.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/HeaderValueHolder.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/HeaderValueHolder.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/HeaderValueHolder.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/HeaderValueHolder.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateCookie.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateCookie.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateCookie.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateCookie.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateResponse.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateResponse.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateResponse.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/bulk/response/IntermediateResponse.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/Categories.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/Categories.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/Categories.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/Categories.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/CategoryWebScript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/CategoryWebScript1.java similarity index 86% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/CategoryWebScript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/CategoryWebScript1.java index b4568970..56451c3b 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/CategoryWebScript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/categories/CategoryWebScript1.java @@ -6,7 +6,7 @@ import eu.xenit.alfred.api.categories.Category; import eu.xenit.alfred.api.categories.ICategoryService; import eu.xenit.alfred.api.data.QName; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import java.util.List; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.GetMapping; @@ -15,7 +15,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class CategoryWebScript1 extends ApixV1Webscript { +public class CategoryWebScript1 extends AlfredApiV1Webscript { private final ICategoryService categoryService; @@ -26,8 +26,8 @@ public CategoryWebScript1(ICategoryService categoryService) { @AlfrescoTransaction(readOnly = true) @GetMapping(value = "/v1/category/aspect/{qname}") public ResponseEntity getCategoriesForAspect(@PathVariable final String qname) { - QName apixQName = new QName(qname); - List categories = categoryService.getCategoryTree(apixQName); + QName alfredApiQName = new QName(qname); + List categories = categoryService.getCategoryTree(alfredApiQName); return writeJsonResponse(new Categories(categories)); } } diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/configuration/ConfigurationWebscript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/configuration/ConfigurationWebscript1.java similarity index 97% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/configuration/ConfigurationWebscript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/configuration/ConfigurationWebscript1.java index 54416a29..420179f6 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/configuration/ConfigurationWebscript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/configuration/ConfigurationWebscript1.java @@ -10,7 +10,7 @@ import eu.xenit.alfred.api.configuration.ConfigurationFileFlags; import eu.xenit.alfred.api.configuration.ConfigurationService; import eu.xenit.alfred.api.configuration.Configurations; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import jakarta.servlet.http.HttpServletRequest; import java.io.IOException; import java.util.Arrays; @@ -29,7 +29,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class ConfigurationWebscript1 extends ApixV1Webscript { +public class ConfigurationWebscript1 extends AlfredApiV1Webscript { private static final Logger log = LoggerFactory.getLogger(ConfigurationWebscript1.class); diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/dictionary/DictionaryWebScript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/dictionary/DictionaryWebScript1.java similarity index 97% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/dictionary/DictionaryWebScript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/dictionary/DictionaryWebScript1.java index c0b6a6aa..03606d85 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/dictionary/DictionaryWebScript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/dictionary/DictionaryWebScript1.java @@ -12,7 +12,7 @@ import eu.xenit.alfred.api.dictionary.types.Types; import eu.xenit.alfred.api.properties.Properties; import eu.xenit.alfred.api.properties.PropertyDefinition; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import jakarta.servlet.http.HttpServletRequest; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -24,7 +24,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class DictionaryWebScript1 extends ApixV1Webscript { +public class DictionaryWebScript1 extends AlfredApiV1Webscript { private static final Logger logger = LoggerFactory.getLogger(DictionaryWebScript1.class); private final IDictionaryService dictionaryService; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/AncestorsObject.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/AncestorsObject.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/AncestorsObject.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/AncestorsObject.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeAclsOptions.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeAclsOptions.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeAclsOptions.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeAclsOptions.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeParentOptions.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeParentOptions.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeParentOptions.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/ChangeParentOptions.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateAssociationOptions.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateAssociationOptions.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateAssociationOptions.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateAssociationOptions.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateNodeOptions.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateNodeOptions.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateNodeOptions.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/CreateNodeOptions.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/InheritFromParent.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/InheritFromParent.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/InheritFromParent.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/InheritFromParent.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfo.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfo.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfo.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfo.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfoRequest.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfoRequest.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfoRequest.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodeInfoRequest.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodesWebscript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodesWebscript1.java similarity index 99% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodesWebscript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodesWebscript1.java index 54e20105..3aa7595f 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodesWebscript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/nodes/NodesWebscript1.java @@ -19,7 +19,7 @@ import eu.xenit.alfred.api.permissions.IPermissionService; import eu.xenit.alfred.api.permissions.NodePermission; import eu.xenit.alfred.api.permissions.PermissionValue; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import eu.xenit.alfred.api.rest.v1.nodes.ChangeAclsOptions.Access; import java.io.IOException; import java.util.HashSet; @@ -52,7 +52,7 @@ @AlfrescoTransaction @RestController -public class NodesWebscript1 extends ApixV1Webscript { +public class NodesWebscript1 extends AlfredApiV1Webscript { private static final Logger logger = LoggerFactory.getLogger(NodesWebscript1.class); diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/people/PeopleWebscript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/people/PeopleWebscript1.java similarity index 95% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/people/PeopleWebscript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/people/PeopleWebscript1.java index 9a83be02..fa4a603c 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/people/PeopleWebscript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/people/PeopleWebscript1.java @@ -4,7 +4,7 @@ import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; import com.gradecak.alfresco.mvc.annotation.AuthenticationType; import eu.xenit.alfred.api.people.IPeopleService; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import java.util.NoSuchElementException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -16,7 +16,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class PeopleWebscript1 extends ApixV1Webscript { +public class PeopleWebscript1 extends AlfredApiV1Webscript { private static final Logger logger = LoggerFactory.getLogger(PeopleWebscript1.class); private final IPeopleService personService; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/properties/PropertiesWebScript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/properties/PropertiesWebScript1.java similarity index 88% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/properties/PropertiesWebScript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/properties/PropertiesWebScript1.java index 2833980d..9278d41d 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/properties/PropertiesWebScript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/properties/PropertiesWebScript1.java @@ -6,7 +6,7 @@ import eu.xenit.alfred.api.data.QName; import eu.xenit.alfred.api.dictionary.properties.IPropertyService; import eu.xenit.alfred.api.properties.PropertyDefinition; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.PathVariable; @@ -19,7 +19,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController @Deprecated(since = "Deprecated since Oct 2015, use DictionaryWebScript1 instead") -public class PropertiesWebScript1 extends ApixV1Webscript { +public class PropertiesWebScript1 extends AlfredApiV1Webscript { private final IPropertyService propertyService; @@ -33,8 +33,8 @@ public PropertiesWebScript1(IPropertyService propertyService) { //https://stackoverflow.com/questions/13482020/encoded-slash-2f-with-spring-requestmapping-path-param-gives-http-400 public ResponseEntity getPropertyDefinition(@PathVariable final QName qname, @RequestParam(required = false) QName qnameWithSlash) { - QName apixQName = qnameWithSlash != null ? qnameWithSlash : qname; - PropertyDefinition propDef = propertyService.GetPropertyDefinition(apixQName); + QName alfredApiQName = qnameWithSlash != null ? qnameWithSlash : qname; + PropertyDefinition propDef = propertyService.GetPropertyDefinition(alfredApiQName); if (propDef == null) { return ResponseEntity.notFound().build(); } diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/search/SearchWebScript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/search/SearchWebScript1.java similarity index 90% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/search/SearchWebScript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/search/SearchWebScript1.java index 91c227dc..7af844b1 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/search/SearchWebScript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/search/SearchWebScript1.java @@ -3,7 +3,7 @@ import com.gradecak.alfresco.mvc.annotation.AlfrescoAuthentication; import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; import com.gradecak.alfresco.mvc.annotation.AuthenticationType; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import eu.xenit.alfred.api.search.ISearchService; import eu.xenit.alfred.api.search.SearchQuery; import org.springframework.http.ResponseEntity; @@ -13,7 +13,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class SearchWebScript1 extends ApixV1Webscript { +public class SearchWebScript1 extends AlfredApiV1Webscript { private final ISearchService service; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SiteInfo.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SiteInfo.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SiteInfo.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SiteInfo.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SitesWebscript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SitesWebscript1.java similarity index 97% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SitesWebscript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SitesWebscript1.java index fa132f9b..7ec5a706 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SitesWebscript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/sites/SitesWebscript1.java @@ -5,7 +5,7 @@ import eu.xenit.alfred.api.filefolder.IFileFolderService; import eu.xenit.alfred.api.node.INodeService; import eu.xenit.alfred.api.permissions.IPermissionService; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import eu.xenit.alfred.api.rest.v1.nodes.NodeInfo; import eu.xenit.alfred.api.sites.ISite; import eu.xenit.alfred.api.sites.ISiteService; @@ -22,7 +22,7 @@ @AlfrescoTransaction @RestController -public class SitesWebscript1 extends ApixV1Webscript { +public class SitesWebscript1 extends AlfredApiV1Webscript { private static final Logger logger = LoggerFactory.getLogger(SitesWebscript1.class); diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/Charsets.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/Charsets.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/Charsets.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/Charsets.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/LogsWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/LogsWebscript.java similarity index 92% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/LogsWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/LogsWebscript.java index 1752b829..d6449d4b 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/LogsWebscript.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/LogsWebscript.java @@ -3,7 +3,7 @@ import com.gradecak.alfresco.mvc.annotation.AlfrescoAuthentication; import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; import com.gradecak.alfresco.mvc.annotation.AuthenticationType; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import java.io.File; import java.io.IOException; import org.springframework.core.env.Environment; @@ -15,7 +15,7 @@ @RestController -public class LogsWebscript extends ApixV1Webscript { +public class LogsWebscript extends AlfredApiV1Webscript { private final String logPath; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/ReversedLinesFileReader.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/ReversedLinesFileReader.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/ReversedLinesFileReader.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/ReversedLinesFileReader.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/WIPWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/WIPWebscript.java similarity index 90% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/WIPWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/WIPWebscript.java index 2b6b7e02..5cee2896 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/WIPWebscript.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/temp/WIPWebscript.java @@ -3,7 +3,7 @@ import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; import eu.xenit.alfred.api.WIP.IWIPService; import eu.xenit.alfred.api.data.NodeRef; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.GetMapping; @@ -11,7 +11,7 @@ import org.springframework.web.bind.annotation.RestController; @RestController("eu.xenit.alfred.api.rest.v1.temp.WIPWebscript") -public class WIPWebscript extends ApixV1Webscript { +public class WIPWebscript extends AlfredApiV1Webscript { private final IWIPService wipService; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/translation/TranslationsWebscript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/translation/TranslationsWebscript1.java similarity index 93% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/translation/TranslationsWebscript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/translation/TranslationsWebscript1.java index 7ecb11cd..3cc25d37 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/translation/TranslationsWebscript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/translation/TranslationsWebscript1.java @@ -1,7 +1,7 @@ package eu.xenit.alfred.api.rest.v1.translation; import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import eu.xenit.alfred.api.translation.ITranslationService; import eu.xenit.alfred.api.translation.Translations; import java.util.Locale; @@ -11,7 +11,7 @@ import org.springframework.web.bind.annotation.RestController; @RestController -public class TranslationsWebscript1 extends ApixV1Webscript { +public class TranslationsWebscript1 extends AlfredApiV1Webscript { private final ITranslationService translationService; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionHistoryWebScript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionHistoryWebScript1.java similarity index 97% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionHistoryWebScript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionHistoryWebScript1.java index c83ab82c..ce82c2ba 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionHistoryWebScript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionHistoryWebScript1.java @@ -4,7 +4,7 @@ import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; import com.gradecak.alfresco.mvc.annotation.AuthenticationType; import eu.xenit.alfred.api.data.QName; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import eu.xenit.alfred.api.versionhistory.IVersionHistoryService; import eu.xenit.alfred.api.versionhistory.Version; import eu.xenit.alfred.api.versionhistory.VersionHistory; @@ -23,7 +23,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class VersionHistoryWebScript1 extends ApixV1Webscript { +public class VersionHistoryWebScript1 extends AlfredApiV1Webscript { private static final Logger logger = LoggerFactory.getLogger(VersionHistoryWebScript1.class); diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionOptions.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionOptions.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionOptions.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/versionhistory/VersionOptions.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckinBody.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckinBody.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckinBody.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckinBody.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckoutBody.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckoutBody.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckoutBody.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/CheckoutBody.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/NoderefResult.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/NoderefResult.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/NoderefResult.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/NoderefResult.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/WorkingcopiesWebscript1.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/WorkingcopiesWebscript1.java similarity index 96% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/WorkingcopiesWebscript1.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/WorkingcopiesWebscript1.java index c9eda5b8..d91ad61b 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/WorkingcopiesWebscript1.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v1/workingcopies/WorkingcopiesWebscript1.java @@ -3,7 +3,7 @@ import com.gradecak.alfresco.mvc.annotation.AlfrescoTransaction; import eu.xenit.alfred.api.data.NodeRef; import eu.xenit.alfred.api.node.INodeService; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.web.bind.annotation.DeleteMapping; @@ -14,7 +14,7 @@ import org.springframework.web.bind.annotation.RestController; @RestController -public class WorkingcopiesWebscript1 extends ApixV1Webscript { +public class WorkingcopiesWebscript1 extends AlfredApiV1Webscript { private final INodeService nodeService; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/ApixV2Webscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/AlfredApiV2Webscript.java similarity index 97% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/ApixV2Webscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/AlfredApiV2Webscript.java index d650ad65..66e7b350 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/ApixV2Webscript.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/AlfredApiV2Webscript.java @@ -10,7 +10,7 @@ import eu.xenit.alfred.api.node.NodeMetadata; import eu.xenit.alfred.api.permissions.IPermissionService; import eu.xenit.alfred.api.permissions.PermissionValue; -import eu.xenit.alfred.api.rest.v1.ApixV1Webscript; +import eu.xenit.alfred.api.rest.v1.AlfredApiV1Webscript; import eu.xenit.alfred.api.rest.v1.nodes.NodeInfo; import eu.xenit.alfred.api.rest.v1.nodes.NodeInfoRequest; import java.util.List; @@ -22,9 +22,9 @@ /** * Created by jasper on 16/02/17. */ -public class ApixV2Webscript extends ApixV1Webscript { +public class AlfredApiV2Webscript extends AlfredApiV1Webscript { - private static final Logger logger = LoggerFactory.getLogger(ApixV2Webscript.class); + private static final Logger logger = LoggerFactory.getLogger(AlfredApiV2Webscript.class); protected List nodeRefToNodeInfo(NodeInfoRequest nodeInfoRequest, IFileFolderService fileFolderService, INodeService nodeService, IPermissionService permissionService) { diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/RestV2Config.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/RestV2Config.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/RestV2Config.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/RestV2Config.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/GroupsWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/GroupsWebscript.java similarity index 98% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/GroupsWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/GroupsWebscript.java index 368d1929..b435d0da 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/GroupsWebscript.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/GroupsWebscript.java @@ -6,7 +6,7 @@ import eu.xenit.alfred.api.groups.Group; import eu.xenit.alfred.api.people.IPeopleService; import eu.xenit.alfred.api.people.Person; -import eu.xenit.alfred.api.rest.v2.ApixV2Webscript; +import eu.xenit.alfred.api.rest.v2.AlfredApiV2Webscript; import java.util.ArrayList; import java.util.Arrays; import java.util.List; @@ -24,7 +24,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class GroupsWebscript extends ApixV2Webscript { +public class GroupsWebscript extends AlfredApiV2Webscript { private static final Logger logger = LoggerFactory.getLogger(GroupsWebscript.class); private final IPeopleService personService; diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetSubgroupOptions.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetSubgroupOptions.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetSubgroupOptions.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetSubgroupOptions.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetUsersInGroupOptions.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetUsersInGroupOptions.java similarity index 100% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetUsersInGroupOptions.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/groups/SetUsersInGroupOptions.java diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/nodes/NodesWebscriptV2.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/nodes/NodesWebscriptV2.java similarity index 98% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/nodes/NodesWebscriptV2.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/nodes/NodesWebscriptV2.java index 4cf29644..c2834886 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/nodes/NodesWebscriptV2.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/nodes/NodesWebscriptV2.java @@ -12,7 +12,7 @@ import eu.xenit.alfred.api.rest.v1.nodes.CreateNodeOptions; import eu.xenit.alfred.api.rest.v1.nodes.NodeInfo; import eu.xenit.alfred.api.rest.v1.nodes.NodeInfoRequest; -import eu.xenit.alfred.api.rest.v2.ApixV2Webscript; +import eu.xenit.alfred.api.rest.v2.AlfredApiV2Webscript; import java.util.List; import java.util.Map; import java.util.concurrent.atomic.AtomicInteger; @@ -30,7 +30,7 @@ @AlfrescoAuthentication @RestController -public class NodesWebscriptV2 extends ApixV2Webscript { +public class NodesWebscriptV2 extends AlfredApiV2Webscript { private static final Logger logger = LoggerFactory.getLogger(NodesWebscriptV2.class); diff --git a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/people/PeopleWebscript.java b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/people/PeopleWebscript.java similarity index 96% rename from apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/people/PeopleWebscript.java rename to alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/people/PeopleWebscript.java index 7f2f9eb3..8b5b8799 100644 --- a/apix-rest/src/main/java/eu/xenit/alfred/api/rest/v2/people/PeopleWebscript.java +++ b/alfred-api-rest/src/main/java/eu/xenit/alfred/api/rest/v2/people/PeopleWebscript.java @@ -5,7 +5,7 @@ import com.gradecak.alfresco.mvc.annotation.AuthenticationType; import eu.xenit.alfred.api.people.IPeopleService; import eu.xenit.alfred.api.people.Person; -import eu.xenit.alfred.api.rest.v2.ApixV2Webscript; +import eu.xenit.alfred.api.rest.v2.AlfredApiV2Webscript; import java.util.ArrayList; import java.util.List; import java.util.NoSuchElementException; @@ -19,7 +19,7 @@ @AlfrescoAuthentication(AuthenticationType.USER) @RestController -public class PeopleWebscript extends ApixV2Webscript { +public class PeopleWebscript extends AlfredApiV2Webscript { private static final Logger logger = LoggerFactory.getLogger(PeopleWebscript.class); private final IPeopleService personService; diff --git a/apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.delete.desc.xml b/alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.delete.desc.xml similarity index 100% rename from apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.delete.desc.xml rename to alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.delete.desc.xml diff --git a/apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.get.desc.xml b/alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.get.desc.xml similarity index 100% rename from apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.get.desc.xml rename to alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.get.desc.xml diff --git a/apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.post.desc.xml b/alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.post.desc.xml similarity index 100% rename from apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.post.desc.xml rename to alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.post.desc.xml diff --git a/apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.put.desc.xml b/alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.put.desc.xml similarity index 100% rename from apix-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.put.desc.xml rename to alfred-api-rest/src/main/resources/alfresco/extension/templates/webscripts/alfred/api.put.desc.xml diff --git a/apix-rest/src/main/resources/alfresco/module/alfred-api/module-context.xml b/alfred-api-rest/src/main/resources/alfresco/module/alfred-api/module-context.xml similarity index 100% rename from apix-rest/src/main/resources/alfresco/module/alfred-api/module-context.xml rename to alfred-api-rest/src/main/resources/alfresco/module/alfred-api/module-context.xml diff --git a/apix-rest/src/main/resources/application.properties b/alfred-api-rest/src/main/resources/application.properties similarity index 100% rename from apix-rest/src/main/resources/application.properties rename to alfred-api-rest/src/main/resources/application.properties diff --git a/apix-rest/src/main/resources/log4j.properties b/alfred-api-rest/src/main/resources/log4j.properties similarity index 100% rename from apix-rest/src/main/resources/log4j.properties rename to alfred-api-rest/src/main/resources/log4j.properties diff --git a/apix-rest/src/test/java/eu/xenit/alfred/api/rest/NodesWebscript1Test.java b/alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/NodesWebscript1Test.java similarity index 100% rename from apix-rest/src/test/java/eu/xenit/alfred/api/rest/NodesWebscript1Test.java rename to alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/NodesWebscript1Test.java diff --git a/apix-rest/src/test/java/eu/xenit/alfred/api/rest/SearchWebscriptTest.java b/alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/SearchWebscriptTest.java similarity index 100% rename from apix-rest/src/test/java/eu/xenit/alfred/api/rest/SearchWebscriptTest.java rename to alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/SearchWebscriptTest.java diff --git a/apix-rest/src/test/java/eu/xenit/alfred/api/rest/TestWebscript1.java b/alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/TestWebscript1.java similarity index 100% rename from apix-rest/src/test/java/eu/xenit/alfred/api/rest/TestWebscript1.java rename to alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/TestWebscript1.java diff --git a/apix-rest/src/test/java/eu/xenit/alfred/api/rest/VersionTest.java b/alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/VersionTest.java similarity index 100% rename from apix-rest/src/test/java/eu/xenit/alfred/api/rest/VersionTest.java rename to alfred-api-rest/src/test/java/eu/xenit/alfred/api/rest/VersionTest.java diff --git a/apix-rest/src/test/resources/log4j.properties b/alfred-api-rest/src/test/resources/log4j.properties similarity index 100% rename from apix-rest/src/test/resources/log4j.properties rename to alfred-api-rest/src/test/resources/log4j.properties diff --git a/apix-rest/src/test/resources/test-context.xml b/alfred-api-rest/src/test/resources/test-context.xml similarity index 100% rename from apix-rest/src/test/resources/test-context.xml rename to alfred-api-rest/src/test/resources/test-context.xml diff --git a/alfresco/build.gradle b/alfresco/build.gradle index 835c8dd6..25f0623e 100644 --- a/alfresco/build.gradle +++ b/alfresco/build.gradle @@ -31,9 +31,9 @@ subprojects { } dependencies { - implementation(project(":apix-impl")) - implementation(project(":apix-impl:apix-impl-${project.name}")) - implementation(project(":apix-rest")) + implementation(project(":alfred-api-impl")) + implementation(project(":alfred-api-impl:alfred-api-impl-${project.name}")) + implementation(project(":alfred-api-rest")) } publishing { @@ -49,7 +49,7 @@ subprojects { // Extend amp plugin task: // We want to add 'alfresco-global.properties' etc to the module-specific folder in the AMP - // (e.g. 'config/module/alfresco/module/apix-impl-61/') without hard-coding project name for each Alfresco version. + // (e.g. 'config/module/alfresco/module/alfred-api-impl-61/') without hard-coding project name for each Alfresco version. amp { archiveBaseName = "alfred-api-${project.name}" into("config/alfresco/module/${project.name}") { diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractQueryConverterFactory.java b/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractQueryConverterFactory.java deleted file mode 100644 index f8244988..00000000 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/AbstractQueryConverterFactory.java +++ /dev/null @@ -1,8 +0,0 @@ -package eu.xenit.alfred.api.alfresco.workflow; - -public interface AbstractQueryConverterFactory { - - AbstractApixQueryConverter getProcessQueryConverter(); - - AbstractApixQueryConverter getTasksQueryConverter(); -} diff --git a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowConverterFactory.java b/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowConverterFactory.java deleted file mode 100644 index a0711b51..00000000 --- a/apix-impl/src/main/java/eu/xenit/alfred/api/alfresco/workflow/WorkflowConverterFactory.java +++ /dev/null @@ -1,8 +0,0 @@ -package eu.xenit.alfred.api.alfresco.workflow; - -public interface WorkflowConverterFactory { - - AbstractApixWorkflowConvertor getProcessInstanceConvertor(); - - AbstractApixWorkflowConvertor getTaskInstanceConvertor(); -} diff --git a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/messages/apixtest.properties b/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/messages/apixtest.properties deleted file mode 100644 index dfcc41ce..00000000 --- a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/messages/apixtest.properties +++ /dev/null @@ -1,5 +0,0 @@ -listconstraint.apixtest_languageConstraint.English=English -listconstraint.apixtest_languageConstraint.French=French -listconstraint.apixtest_languageConstraint.Dutch=Dutch -listconstraint.apixtest_languageConstraint.German=German - diff --git a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/messages/apixtest_nl.properties b/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/messages/apixtest_nl.properties deleted file mode 100644 index 0b8c0d65..00000000 --- a/apix-integrationtests-client/model-amp/src/main/amp/config/alfresco/module/apix-integrationtests-model-amp/messages/apixtest_nl.properties +++ /dev/null @@ -1,5 +0,0 @@ -listconstraint.apixtest_languageConstraint.English=Engels -listconstraint.apixtest_languageConstraint.French=Frans -listconstraint.apixtest_languageConstraint.Dutch=Nederlands -listconstraint.apixtest_languageConstraint.German=Duits - diff --git a/docs/build-website.sh b/docs/build-website.sh index 68e1ec78..c2e6c111 100755 --- a/docs/build-website.sh +++ b/docs/build-website.sh @@ -62,12 +62,12 @@ build_javadoc() { local alfredapidir=".." pushd "$alfredapidir" - ./gradlew :apix-interface:javadoc + ./gradlew :alfred-api-interface:javadoc popd local outputdir="build/website/$productName/" mkdir -p "$outputdir" - cp -a "$alfredapidir/apix-interface/build/docs/javadoc" $outputdir + cp -a "$alfredapidir/alfred-api-interface/build/docs/javadoc" $outputdir } build_swaggerdoc() { diff --git a/docs/user/user-guide.md b/docs/user/user-guide.md index 261e3944..97bf7788 100644 --- a/docs/user/user-guide.md +++ b/docs/user/user-guide.md @@ -29,7 +29,7 @@ ContentData and ContentInputStream. These data objects are used to communicate w Alfred Java API without being dependent on Alfresco data types. Conversion between Alfresco and Alfred API data objects is the responsibility of the -`ApixToAlfrescoConversion` service. It is also possible to construct an Alfred API data object by +`AlfredApiToAlfrescoConversion` service. It is also possible to construct an Alfred API data object by passing its string representation to the constructor. diff --git a/settings.gradle b/settings.gradle index e3f38fd1..24d13ec5 100644 --- a/settings.gradle +++ b/settings.gradle @@ -1,24 +1,24 @@ -rootProject.name = 'apix' +rootProject.name = 'alfred-api' -include ':apix-interface' -include ':apix-impl' -include ':apix-rest' +include ':alfred-api-interface' +include ':alfred-api-impl' +include ':alfred-api-rest' include ':alfresco' -include ':apix-docker' -include ':apix-integrationtests-client:model-amp' -include ':apix-integrationtests-server' +include ':alfred-api-docker' +include ':alfred-api-integrationtests-client:model-amp' +include ':alfred-api-integrationtests-server' include ':docs' for (String version : ['23.1', '23.2']) { def shortVersion = version.replaceAll('\\.', '') - include ":apix-impl:apix-impl-$shortVersion" + include ":alfred-api-impl:alfred-api-impl-$shortVersion" include ":alfresco:$shortVersion" - include ":apix-docker:docker-$shortVersion" - include ":apix-integrationtests-client:alfresco:$shortVersion" + include ":alfred-api-docker:docker-$shortVersion" + include ":alfred-api-integrationtests-client:alfresco:$shortVersion" - project(":apix-impl:apix-impl-$shortVersion").projectDir = "$rootDir/apix-impl/$shortVersion" as File - project(":apix-docker:docker-$shortVersion").projectDir = "$rootDir/apix-docker/$shortVersion" as File + project(":alfred-api-impl:alfred-api-impl-$shortVersion").projectDir = "$rootDir/alfred-api-impl/$shortVersion" as File + project(":alfred-api-docker:docker-$shortVersion").projectDir = "$rootDir/alfred-api-docker/$shortVersion" as File project(":alfresco:$shortVersion").projectDir = "$rootDir/alfresco/$shortVersion" as File } \ No newline at end of file