Class: Rafflesia::DatasetBuildRequest

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/rafflesia/datasets/dataset_build_request.rb

Constant Summary collapse

HASH_ATTRS =
{
  compact: :compact,
  compact_shard_size: :compact_shard_size,
  dataset_name: :dataset_name,
  dataset_version: :dataset_version,
  dry_run: :dry_run,
  from_manifest_path: :from_manifest_path,
  input_dir: :input_dir,
  input_paths: :input_paths,
  manifest_path: :manifest_path,
  max_failure_count: :max_failure_count,
  output_dir: :output_dir,
  pocket_backend: :pocket_backend,
  pocket_cache_mode: :pocket_cache_mode,
  profile: :profile,
  recursive: :recursive,
  response_mode: :response_mode,
  resume: :resume,
  source: :source,
  tables: :tables,
  target_namespace: :target_namespace,
  threshold: :threshold
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ DatasetBuildRequest

Returns a new instance of DatasetBuildRequest.



55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 55

def initialize(json)
  super()
  hash = self.class.normalize(json)
  @compact = hash[:compact]
  @compact_shard_size = hash[:compact_shard_size]
  @dataset_name = hash[:dataset_name]
  @dataset_version = hash[:dataset_version]
  @dry_run = hash[:dry_run]
  @from_manifest_path = hash[:from_manifest_path]
  @input_dir = hash[:input_dir]
  @input_paths = (hash[:input_paths] || [])
  @manifest_path = hash[:manifest_path]
  @max_failure_count = hash[:max_failure_count]
  @output_dir = hash[:output_dir]
  @pocket_backend = hash[:pocket_backend]
  @pocket_cache_mode = hash[:pocket_cache_mode]
  @profile = hash[:profile]
  @recursive = hash[:recursive]
  @response_mode = hash[:response_mode]
  @resume = hash[:resume]
  @source = hash[:source]
  @tables = (hash[:tables] || [])
  @target_namespace = hash[:target_namespace]
  @threshold = hash[:threshold]
end

Instance Attribute Details

#compactObject

Returns the value of attribute compact.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def compact
  @compact
end

#compact_shard_sizeObject

Returns the value of attribute compact_shard_size.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def compact_shard_size
  @compact_shard_size
end

#dataset_nameObject

Returns the value of attribute dataset_name.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def dataset_name
  @dataset_name
end

#dataset_versionObject

Returns the value of attribute dataset_version.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def dataset_version
  @dataset_version
end

#dry_runObject

Returns the value of attribute dry_run.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def dry_run
  @dry_run
end

#from_manifest_pathObject

Returns the value of attribute from_manifest_path.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def from_manifest_path
  @from_manifest_path
end

#input_dirObject

Returns the value of attribute input_dir.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def input_dir
  @input_dir
end

#input_pathsObject

Returns the value of attribute input_paths.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def input_paths
  @input_paths
end

#manifest_pathObject

Returns the value of attribute manifest_path.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def manifest_path
  @manifest_path
end

#max_failure_countObject

Returns the value of attribute max_failure_count.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def max_failure_count
  @max_failure_count
end

#output_dirObject

Returns the value of attribute output_dir.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def output_dir
  @output_dir
end

#pocket_backendObject

Returns the value of attribute pocket_backend.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def pocket_backend
  @pocket_backend
end

#pocket_cache_modeObject

Returns the value of attribute pocket_cache_mode.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def pocket_cache_mode
  @pocket_cache_mode
end

#profileObject

Returns the value of attribute profile.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def profile
  @profile
end

#recursiveObject

Returns the value of attribute recursive.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def recursive
  @recursive
end

#response_modeObject

Returns the value of attribute response_mode.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def response_mode
  @response_mode
end

#resumeObject

Returns the value of attribute resume.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def resume
  @resume
end

#sourceObject

Returns the value of attribute source.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def source
  @source
end

#tablesObject

Returns the value of attribute tables.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def tables
  @tables
end

#target_namespaceObject

Returns the value of attribute target_namespace.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def target_namespace
  @target_namespace
end

#thresholdObject

Returns the value of attribute threshold.



32
33
34
# File 'lib/rafflesia/datasets/dataset_build_request.rb', line 32

def threshold
  @threshold
end