Sha256: 0c9cf1c6f3d22c113aee31495a65ab0a8e9cb43b101e7181471204d3dc8cc0e4

Contents?: true

Size: 628 Bytes

Versions: 3

Compression:

Stored size: 628 Bytes

Contents

module OpenTox

  module Validation

    # Base validation class
    class Validation
      include OpenTox
      include Mongoid::Document
      include Mongoid::Timestamps
      store_in collection: "validations"
      field :name, type: String
      field :model_id, type: BSON::ObjectId
      field :nr_instances, type: Integer, default: 0
      field :nr_unpredicted, type: Integer, default: 0
      field :predictions, type: Hash, default: {}
      field :finished_at, type: Time 

      # Get model
      # @return [OpenTox::Model::Lazar]
      def model
        Model::Lazar.find model_id
      end

    end

  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
lazar-1.1.3 lib/validation.rb
lazar-1.1.0 lib/validation.rb
lazar-1.0.1 lib/validation.rb