Class: Dcm4chee::TrashedDicomFile

Inherits:
Object
  • Object
show all
Includes:
DataMapper::Resource, DataMapper::Searcher, HasDicomObject
Defined in:
app/models/dcm4chee/trashed_dicom_file.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from HasDicomObject

#as_json, #dcm_elements

Class Method Details

.repository(name = nil, &block) ⇒ Object



54
55
56
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 54

def self.repository(name = nil, &block)
  super(Dcm4chee.config.repository_name, &block)
end

Instance Method Details

#availabilityInteger

Availability:

-4: QUERY_HSM_FAILED
-3: MD5_CHECK_FAILED
-2: VERIFY_COMPRESS_FAILED
-1: COMPRESS_FAILED
 0: DEFAULT
 1: TO_ARCHIVE
 2: ARCHIVED
 3: COMPRESSING

Returns:

  • (Integer)

    file status



43
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 43

property :availability, Enum[-4, -3, -2, -1, 0, 1, 2, 3], field: 'file_status'

#dcmDICOM::DObject

Load the dicom object from file

Returns:

  • (DICOM::DObject)

    DICOM object



50
51
52
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 50

def dcm
  @dcm ||= DICOM::DObject.read(File.join(file_system.path, path))
end

#file_system_idInteger

Returns foreign key of FileSystem.

Returns:



18
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 18

property :file_system_id, Integer, field: 'filesystem_fk'

#idInteger

Returns primary key.

Returns:

  • (Integer)

    primary key



12
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 12

property :id, Serial, field: 'pk'

#md5String

Returns MD5 of the file.

Returns:

  • (String)

    MD5 of the file



27
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 27

property :md5, String, field: 'file_md5'

#pathString

Returns path.

Returns:

  • (String)

    path



21
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 21

property :path, Text, field: 'filepath'

#sizeInteger

Returns file size.

Returns:

  • (Integer)

    file size



30
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 30

property :size, Integer, field: 'file_size'

#transfer_syntax_uidString

Returns DICOM Transfer Syntax UID(0002,0010).

Returns:

  • (String)

    DICOM Transfer Syntax UID(0002,0010)



24
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 24

property :transfer_syntax_uid, Text, field: 'file_tsuid'

#trashed_instance_idInteger

Returns foreign key of Instance.

Returns:



15
# File 'app/models/dcm4chee/trashed_dicom_file.rb', line 15

property :trashed_instance_id, Integer, field: 'instance_fk'