001/** 002 * Copyright 2016 Tampere University of Technology, Pori Department 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 service.tut.pori.apilta.alerts.datatypes; 017 018import core.tut.pori.dao.SolrDAO; 019 020/** 021 * definitions for alerts package data types 022 * 023 */ 024public final class Definitions { 025 /* elements */ 026 /** xml element declaration */ 027 public static final String ELEMENT_ALERT = "alert"; 028 /** xml element declaration */ 029 public static final String ELEMENT_ALERT_GROUP = "alertGroup"; 030 /** xml element declaration */ 031 public static final String ELEMENT_ALERT_GROUP_ID = "alertGroupId"; 032 /** xml element declaration */ 033 public static final String ELEMENT_ALERT_ID = "alertId"; 034 /** xml element declaration */ 035 public static final String ELEMENT_ALERT_LIST = "alertList"; 036 /** xml element declaration */ 037 public static final String ELEMENT_ALERT_TYPE = "alertType"; 038 /** xml element declaration */ 039 public static final String ELEMENT_CREATED_TIMESTAMP = "createdTimestamp"; 040 /** xml element declaration */ 041 public static final String ELEMENT_DESCRIPTION = "description"; 042 /** xml element declaration */ 043 public static final String ELEMENT_HEADING = "heading"; 044 /** xml element declaration */ 045 public static final String ELEMENT_LATITUDE = "latitude"; 046 /** xml element declaration */ 047 public static final String ELEMENT_LOCATION = "location"; 048 /** xml element declaration */ 049 public static final String ELEMENT_LONGITUDE = "longitude"; 050 /** xml element declaration */ 051 public static final String ELEMENT_NAME = "name"; 052 /** xml element declaration */ 053 public static final String ELEMENT_PERMISSION = "permission"; 054 /** xml element declaration */ 055 public static final String ELEMENT_PERMISSION_LIST = "permissionList"; 056 /** xml element declaration */ 057 public static final String ELEMENT_RANGE = "range"; 058 /** xml element declaration */ 059 public static final String ELEMENT_VALID_TIMESTAMP = "validTimestamp"; 060 061 /* solr fields */ 062 /* solr dynamic field datatypes */ 063 /** SOLR field declaration */ 064 public static final String SOLR_FIELD_ALERT_GROUP_ID = ELEMENT_ALERT_GROUP_ID+"_ll"; 065 /** SOLR field declaration */ 066 public static final String SOLR_FIELD_ALERT_TYPE = ELEMENT_ALERT_TYPE+SolrDAO.SOLR_STRING; 067 /** SOLR field declaration */ 068 public static final String SOLR_FIELD_DESCRIPTION = ELEMENT_DESCRIPTION+SolrDAO.SOLR_STRING; 069 /** SOLR field declaration */ 070 public static final String SOLR_FIELD_FILE_GUIDS = "fileGUIDs"+SolrDAO.SOLR_STRING_LIST; 071 /** SOLR field declaration */ 072 public static final String SOLR_FIELD_LOCATION = "location"; 073 /** SOLR field declaration */ 074 public static final String SOLR_FIELD_RANGE = ELEMENT_RANGE+SolrDAO.SOLR_INTEGER; 075 /** SOLR field declaration */ 076 public static final String SOLR_FIELD_USER_ID = core.tut.pori.users.Definitions.ELEMENT_USER_ID+SolrDAO.SOLR_LONG; 077 /** SOLR field declaration */ 078 public static final String SOLR_FIELD_VALID = ELEMENT_VALID_TIMESTAMP+SolrDAO.SOLR_DATE; 079 080 /** 081 * 082 */ 083 private Definitions() { 084 // nothing needed 085 } 086}