Sha256: 573608103a687b12d84492f8214d49efecbfcf2092cfbcafcb8d6a96e32f1555

Contents?: true

Size: 809 Bytes

Versions: 2

Compression:

Stored size: 809 Bytes

Contents

require 'chronicle/etl/models/base'

module Chronicle
  module ETL
    module Models
      class Entity < Chronicle::ETL::Models::Base
        TYPE = 'entities'.freeze
        ATTRIBUTES = [:title, :body, :provider_url, :represents, :slug, :myself, :metadata].freeze

        # TODO: This desperately needs a validation system
        ASSOCIATIONS = [
          :involvements, # inverse of activity's `involved`
          :analogous,
          :attachments,
          :abouts,
          :aboutables, # inverse of above
          :depicts,
          :consumers,
          :creators,
          :creations,
          :contains,
          :containers # inverse of above
        ].freeze  # TODO: add these to reflect Chronicle Schema

        attr_accessor(*ATTRIBUTES, *ASSOCIATIONS)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
chronicle-etl-0.5.5 lib/chronicle/etl/models/entity.rb
chronicle-etl-0.5.4 lib/chronicle/etl/models/entity.rb