Class: OpenUSD::PseudoRoot

Inherits:
Object
  • Object
show all
Defined in:
lib/openusd/prim.rb

Overview

Synthetic root for a Stage's root prims.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(stage) ⇒ PseudoRoot

Returns a new instance of PseudoRoot.



122
123
124
# File 'lib/openusd/prim.rb', line 122

def initialize(stage)
  @stage = stage
end

Instance Attribute Details

#stageObject (readonly)

Returns the value of attribute stage.



120
121
122
# File 'lib/openusd/prim.rb', line 120

def stage
  @stage
end

Instance Method Details

#childrenArray<Prim>

Returns active root prims.

Returns:

  • (Array<Prim>)

    active root prims



147
148
149
# File 'lib/openusd/prim.rb', line 147

def children
  stage.root_paths.filter_map { |root_path| stage.prim_at(root_path) }
end

#nameString

Returns empty pseudo-root name.

Returns:

  • (String)

    empty pseudo-root name



132
133
134
# File 'lib/openusd/prim.rb', line 132

def name
  ""
end

#parentnil

Returns:

  • (nil)


142
143
144
# File 'lib/openusd/prim.rb', line 142

def parent
  nil
end

#pathPath

Returns pseudo-root path.

Returns:

  • (Path)

    pseudo-root path



127
128
129
# File 'lib/openusd/prim.rb', line 127

def path
  Path.parse("/")
end

#type_namenil

Returns:

  • (nil)


137
138
139
# File 'lib/openusd/prim.rb', line 137

def type_name
  nil
end