All Implemented Interfaces:
Serializable

@ValidInstrumentIdPattern(message="instrument-management.error.instrument.valid-instrument-id-pattern")
@ValidUniqueInstrumentNumber(message="instrument-management.error.instrument.unique-instrument-number")
@CompoundIndex(def="{number: 1, dataAcquisitionProjectId: 1}",
               unique=true)
@ValidShadowId(message="instrument-management.error.instrument.derived-id.pattern")
public class Instrument
extends AbstractShadowableRdcDomainObject
An instrument (e.g. a questionnaire) which was used in at least one Survey.
See Also:
Serialized Form
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
      Constant Field Values
    • id

      @NotEmpty(message="instrument-management.error.instrument.id.not-empty") private @NotEmpty(message="instrument-management.error.instrument.id.not-empty") String id
      The id of the instrument which uniquely identifies the instrument in this application.
    • masterId

      @NotEmpty(message="instrument-management.error.instrument.master-id.not-empty") @Size(max=512, message="instrument-management.error.instrument.master-id.size") @Pattern(regexp="^[_A-Za-z0-9\u00e4\u00f6\u00fc\u00c4\u00d6\u00dc\u00df\\-\\$]*$", message="instrument-management.error.instrument.master-id.pattern") private @NotEmpty(message="instrument-management.error.instrument.master-id.not-empty") @Size(max=512,message="instrument-management.error.instrument.master-id.size") @Pattern(regexp="^[_A-Za-z0-9\u00e4\u00f6\u00fc\u00c4\u00d6\u00dc\u00df\\-\\$]*$",message="instrument-management.error.instrument.master-id.pattern") String masterId
      The instrument's master id. It must not be empty, must be of the form ins-{{dataAcquisitionProjectId}}-ins{{number}}$ and must not contain more than 512 characters.
    • dataAcquisitionProjectId

      @NotEmpty(message="instrument-management.error.instrument.data-acquisition-project-id.not-empty") private @NotEmpty(message="instrument-management.error.instrument.data-acquisition-project-id.not-empty") String dataAcquisitionProjectId
      The id of the DataAcquisitionProject to which this instrument belongs. The dataAcquisitionProjectId must not be empty.
    • title

      @NotNull(message="instrument-management.error.instrument.title.not-null") @I18nStringSize(max=2048, message="instrument-management.error.instrument.title.i18n-string-size") @I18nStringNotEmpty(message="instrument-management.error.instrument.title.i18n-string-not-empty") private @NotNull(message="instrument-management.error.instrument.title.not-null") @I18nStringSize(max=2048,message="instrument-management.error.instrument.title.i18n-string-size") I18nString title
      The title of the instrument. It must be specified in at least one language and it must not contain more than 2048 characters.
    • subtitle

      @I18nStringSize(max=2048, message="instrument-management.error.instrument.subtitle.i18n-string-size") private @I18nStringSize(max=2048,message="instrument-management.error.instrument.subtitle.i18n-string-size") I18nString subtitle
      An optional subtitle of the instrument. It must not contain more than 2048 characters.
    • description

      @NotNull(message="instrument-management.error.instrument.description.not-null") @I18nStringSize(max=512, message="instrument-management.error.instrument.description.i18n-string-size") @I18nStringNotEmpty(message="instrument-management.error.instrument.description.i18n-string-not-empty") private @NotNull(message="instrument-management.error.instrument.description.not-null") @I18nStringSize(max=512,message="instrument-management.error.instrument.description.i18n-string-size") I18nString description
      A short description of the instrument. It must be specified in at least one language and it must not contain more than 512 characters.
    • number

      @NotNull(message="instrument-management.error.instrument.number.not-null") private @NotNull(message="instrument-management.error.instrument.number.not-null") Integer number
      The number of the instrument. Must not be empty and must be unique within the DataAcquisitionProject.
    • type

      @NotEmpty(message="instrument-management.error.instrument.type.not-empty") @ValidInstrumentType(message="instrument-management.error.instrument.type.valid") private @NotEmpty(message="instrument-management.error.instrument.type.not-empty") String type
      The type of this instrument. Must be one of InstrumentTypes and must not be empty.
    • annotations

      @I18nStringSize(max=2048, message="instrument-management.error.instrument.annotations.i18n-string-size") private @I18nStringSize(max=2048,message="instrument-management.error.instrument.annotations.i18n-string-size") I18nString annotations
      Arbitrary additional text for this instrument. Markdown is supported. Must not contain more than 2048 characters.
    • surveyIds

      @NotEmpty(message="instrument-management.error.instrument.survey-ids.not-empty") private @NotEmpty(message="instrument-management.error.instrument.survey-ids.not-empty") List<String> surveyIds
      List of ids of Surveys of this DataAcquisitionProject. The instrument has been used in these Surveys. Must contain at least one element.
    • surveyNumbers

      @NotEmpty(message="instrument-management.error.instrument.survey-numbers.not-empty") private @NotEmpty(message="instrument-management.error.instrument.survey-numbers.not-empty") List<Integer> surveyNumbers
      List of numbers of Surveys of this DataAcquisitionProject. The instrument has been used in these Surveys. Must contain at least one element.
    • dataPackageId

      @NotEmpty(message="instrument-management.error.instrument.dataPackage-id.not-empty") private @NotEmpty(message="instrument-management.error.instrument.dataPackage-id.not-empty") String dataPackageId
      The id of the OrderedDataPackage to which this instrument belongs. Must not be empty.
    • conceptIds

      private List<@ConceptExists(message="instrument-management.error.instrument.concept-ids.not-exists") String> conceptIds
      List of ids of Concepts to which are covered by this instrument.
    • originalLanguages

      private List<@ValidIsoLanguage(message="instrument-management.error.instrument.original-languages.not-supported") String> originalLanguages
      The languages of the instrument during the data collection. Must be specified as ISO 639 language codes.
  • Constructor Details

    • Instrument

      public Instrument​(Instrument instrument)
  • Method Details