Class: Google::Apis::GenomicsV1::Position

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/genomics_v1/classes.rb,
generated/google/apis/genomics_v1/representations.rb,
generated/google/apis/genomics_v1/representations.rb

Overview

An abstraction for referring to a genomic position, in relation to some already known reference. For now, represents a genomic position as a reference name, a base number on that reference (0-based), and a determination of forward or reverse strand.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Position

Returns a new instance of Position.



1983
1984
1985
# File 'generated/google/apis/genomics_v1/classes.rb', line 1983

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#positionString

The 0-based offset from the start of the forward strand for that reference. Corresponds to the JSON property position

Returns:

  • (String)


1974
1975
1976
# File 'generated/google/apis/genomics_v1/classes.rb', line 1974

def position
  @position
end

#reference_nameString

The name of the reference in whatever reference set is being used. Corresponds to the JSON property referenceName

Returns:

  • (String)


1969
1970
1971
# File 'generated/google/apis/genomics_v1/classes.rb', line 1969

def reference_name
  @reference_name
end

#reverse_strandBoolean Also known as: reverse_strand?

Whether this position is on the reverse strand, as opposed to the forward strand. Corresponds to the JSON property reverseStrand

Returns:

  • (Boolean)


1980
1981
1982
# File 'generated/google/apis/genomics_v1/classes.rb', line 1980

def reverse_strand
  @reverse_strand
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1988
1989
1990
1991
1992
# File 'generated/google/apis/genomics_v1/classes.rb', line 1988

def update!(**args)
  @reference_name = args[:reference_name] if args.key?(:reference_name)
  @position = args[:position] if args.key?(:position)
  @reverse_strand = args[:reverse_strand] if args.key?(:reverse_strand)
end