001/* 002 * Copyright 2015 Anyware Services 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package org.ametys.cms.content.indexing.solr; 017 018/** 019 * Constants for Solr field names related to indexation. 020 */ 021public interface SolrFieldNames 022{ 023 //// CMS 024 025 /** Document type. */ 026 public static final String DOCUMENT_TYPE = "_documentType"; 027 028 /** Repeater entry position. */ 029 public static final String REPEATER_ENTRY_POSITION = "_position"; 030 031 /** Document type for a content */ 032 public static final String TYPE_CONTENT = "content"; 033 /** Document type for a content repeater */ 034 public static final String TYPE_REPEATER = "repeater"; 035 /** Document type for a resource */ 036 public static final String TYPE_RESOURCE = "resource"; 037 /** Document type for a workflow entry. */ 038 public static final String TYPE_WF_ENTRY = "workflowEntry"; 039 /** Document type for a workflow step. */ 040 public static final String TYPE_WF_STEP = "workflowStep"; 041 042 /** Id field name. */ 043 public static final String ID = "id"; 044 /** Title field name. */ 045 public static final String TITLE = "title"; 046 /** Page title for sorting field name. */ 047 public static final String TITLE_SORT = "title_sort"; 048 049 /** Unstemmed full-text field prefix */ 050 public static final String FULL_PREFIX = "full_"; 051 /** Stemmed full-text field prefix. */ 052 public static final String FULL_STEMMED_PREFIX = "full_stemmed_"; 053 /** Full-text field name with general text indexation. */ 054 public static final String FULL_GENERAL = "full"; 055 /** Full-text with simple white-space tokenization. */ 056 public static final String FULL_EXACT_WS = "full_s_ws"; 057 /** Last modified date field name. */ 058 public static final String LAST_MODIFIED = "lastModified"; 059 /** Creation date field name. */ 060 public static final String CREATION_DATE = "creationDate"; 061 /** Last validation date field name. */ 062 public static final String LAST_VALIDATION = "lastValidation"; 063 /** Last major validation date field name. */ 064 public static final String LAST_MAJOR_VALIDATION = "lastMajorValidation"; 065 066 /** Comments status of a content. */ 067 public static final String CONTENT_COMMENTS = "comments"; 068 /** Validated comments of a content. */ 069 public static final String CONTENT_COMMENTS_VALIDATED = "commentsValidated"; 070 /** Non-validated comments of a content. */ 071 public static final String CONTENT_COMMENTS_NONVALIDATED = "commentsNonValidated"; 072 073 /** Content name field name. */ 074 public static final String CONTENT_NAME = "contentName"; 075 /** Content types field name. */ 076 public static final String CONTENT_TYPES = "contentTypes"; 077 /** All content types field name. */ 078 public static final String ALL_CONTENT_TYPES = "allContentTypes"; 079 /** Mixin types field name. */ 080 public static final String MIXIN_TYPES = "mixinTypes"; 081 /** All mixin types field name. */ 082 public static final String ALL_MIXIN_TYPES = "allMixinTypes"; 083// /** The content types and mixins of a content. */ 084// public static final String CONTENT_TYPE_OR_MIXIN = "contentTypeOrMixin"; 085 /** Content language field name. */ 086 public static final String CONTENT_LANGUAGE = "contentLanguage"; 087 /** The content current workflow step. */ 088 public static final String WORKFLOW_STEP = "workflowStep"; 089 /** Content creator field name. */ 090 public static final String CONTENT_CREATOR = "creator"; 091 /** Content last contributor field name. */ 092 public static final String CONTENT_LAST_CONTRIBUTOR = "contributor"; 093 /** Tags field name. */ 094 public static final String TAGS = "tags"; 095 /** All tags (including parent ones). */ 096 public static final String ALL_TAGS = "allTags"; 097 098 /** Content: embedded mode. */ 099 /** Content titles field name. */ 100 public static final String CONTENT_TITLES = "content-titles"; 101 /** Content languages field. */ 102 public static final String CONTENT_LANGUAGES = "content-languages"; 103 /** Sub-content field name. */ 104 public static final String SUB_CONTENT = "subContent"; 105 106 /** Resource excerpt field name. */ 107 public static final String EXCERPT = "excerpt"; 108 /** The file name for resources. */ 109 public static final String FILENAME = "filename"; 110 /** The resource path */ 111 public static final String PATH = "path"; 112 /** The mime type for resources. */ 113 public static final String MIME_TYPES = "mimeTypes"; 114 /** The length of a resource. */ 115 public static final String LENGTH = "length"; 116 /** The dummy "content type" of a resource. */ 117 public static final String CONTENT_TYPE_RESOURCE = "resource"; 118 /** The resource root ID */ 119 public static final String RESOURCE_ROOT_ID = "resourceRootId"; 120 /** The resource author */ 121 public static final String RESOURCE_CREATOR = "resourceCreator"; 122 /** The resource date */ 123 public static final String RESOURCE_DATE = "resourceDate"; 124 /** Last modified date field name. */ 125 public static final String RESOURCE_LAST_MODIFIED = "last-modified"; 126 127 //// Date facet 128 // TODO Use docValues ? 129 /** Date facet field. */ 130 public static final String DATES_FACET = "dates-facet"; 131 /** Date sorting */ 132 public static final String DATE_FOR_SORTING = "date-for-sorting"; 133 134 //// Dublin Core metadatas 135 /** Dublin Core title. */ 136 public static final String DC_TITLE = "DCTitle"; 137 /** Dublin Core creator. */ 138 public static final String DC_CREATOR = "DCCreator"; 139 /** Dublin Core subject. */ 140 public static final String DC_SUBJECT = "DCSubject"; 141 /** Dublin Core description. */ 142 public static final String DC_DESCRIPTION = "DCDescription"; 143 /** Dublin Core publisher. */ 144 public static final String DC_PUBLISHER = "DCPublisher"; 145 /** Dublin Core contributor. */ 146 public static final String DC_CONTRIBUTOR = "DCContributor"; 147 /** Dublin Core date. */ 148 public static final String DC_DATE = "DCDate"; 149 /** Dublin Core type. */ 150 public static final String DC_TYPE = "DCType"; 151 /** Dublin Core format. */ 152 public static final String DC_FORMAT = "DCFormat"; 153 /** Dublin Core identifier. */ 154 public static final String DC_IDENTIFIER = "DCIdentifier"; 155 /** Dublin Core source. */ 156 public static final String DC_SOURCE = "DCSource"; 157 /** Dublin Core language. */ 158 public static final String DC_LANGUAGE = "DCLanguage"; 159 /** Dublin Core relation. */ 160 public static final String DC_RELATION = "DCRelation"; 161 /** Dublin Core coverage. */ 162 public static final String DC_COVERAGE = "DCCoverage"; 163 /** Dublin Core rights. */ 164 public static final String DC_RIGHTS = "DCRights"; 165 166 //// Workflow fields. 167 /** Constant for workflow reference field (on the AmetysObject itself). */ 168 public static final String WORKFLOW_REF = "workflowRef"; 169 /** Constant for workflow reference field with suffix (on the AmetysObject itself). */ 170 public static final String WORKFLOW_REF_DV = "workflowRef_s_dv"; 171 /** Constant for workflow name field. */ 172 public static final String WORKFLOW_NAME = "wfName"; 173 /** Constant for workflow entry state field. */ 174 public static final String WORKFLOW_ENTRY_STATE = "wfEntryState"; 175 /** Constant for workflow history steps field. */ 176 public static final String WORKFLOW_HISTORY_STEPS = "wfHistorySteps"; 177 /** Constant for workflow history steps field (with suffix). */ 178 public static final String WORKFLOW_HISTORY_STEPS_DV = WORKFLOW_HISTORY_STEPS + "_s_dv"; 179 /** Constant for workflow current steps field. */ 180 public static final String WORKFLOW_CURRENT_STEPS = "wfCurrentSteps"; 181 /** Constant for workflow current steps field (with suffix). */ 182 public static final String WORKFLOW_CURRENT_STEPS_DV = WORKFLOW_CURRENT_STEPS + "_s_dv"; 183 /** Constant for workflow step ID field. */ 184 public static final String WORKFLOW_STEP_ID = "wfStepId"; 185 /** Constant for workflow step action ID field. */ 186 public static final String WORKFLOW_STEP_ACTIONID = "wfStepActionId"; 187 /** Constant for workflow step owner field. */ 188 public static final String WORKFLOW_STEP_OWNER = "wfStepOwner"; 189 /** Constant for workflow step caller field. */ 190 public static final String WORKFLOW_STEP_CALLER = "wfStepCaller"; 191 /** Constant for workflow step start date field. */ 192 public static final String WORKFLOW_STEP_STARTDATE = "wfStepStartDate"; 193 /** Constant for workflow step due date field. */ 194 public static final String WORKFLOW_STEP_DUEDATE = "wfStepDueDate"; 195 /** Constant for workflow step finish date field. */ 196 public static final String WORKFLOW_STEP_FINISHDATE = "wfStepFinishDate"; 197 /** Constant for workflow step status field. */ 198 public static final String WORKFLOW_STEP_STATUS = "wfStepStatus"; 199 200 //// ACL fields. 201 /** Constant for allow anonymous status for reader profile. */ 202 public static final String ACL_READ_ALLOW_ANONYMOUS = "aclReadAllowAnonymous"; 203 /** Constant for allow any connected user status for reader profile. */ 204 public static final String ACL_READ_ALLOW_ANY_CONNECTED_USER = "aclReadAllowAnyConnectedUser"; 205 /** Constant for allowed users for reader profile. */ 206 public static final String ACL_READ_ALLOWED_USERS = "aclReadAllowedUsers"; 207 /** Constant for allowed groups for reader profile. */ 208 public static final String ACL_READ_ALLOWED_GROUPS = "aclReadAllowedGroups"; 209 /** Constant for denied users for reader profile. */ 210 public static final String ACL_READ_DENIED_USERS = "aclReadDeniedUsers"; 211 /** Constant for denied groups for reader profile. */ 212 public static final String ACL_READ_DENIED_GROUPS = "aclReadDeniedGroups"; 213}