Class: Udb::FullConfig
- Inherits:
-
AbstractConfig
- Object
- AbstractConfig
- Udb::FullConfig
- Defined in:
- lib/udb/config.rb
Overview
This class represents a configuration that is “fully-configured” (e.g., SoC tapeout or fully-configured IP). # It has a complete list of extensions and parameters (all are a single value at this point). #
Instance Method Summary collapse
- #fully_configured? ⇒ Boolean
- #implemented_extensions ⇒ Array<Hash{String => String}>
-
#initialize(data, info)
constructor
NON-ABSTRACT METHODS #.
- #mxlen ⇒ Integer
-
#param_values ⇒ Hash{String => ParamValueType}
ABSTRACT METHODS OVERRIDDEN #.
- #partially_configured? ⇒ Boolean
- #unconfigured? ⇒ Boolean
Constructor Details
#initialize(data, info)
NON-ABSTRACT METHODS #
285 286 287 288 289 290 291 292 |
# File 'lib/udb/config.rb', line 285 def initialize(data, info) super(data, info) @param_values = @data["params"] @mxlen = @data.dig("params", "MXLEN").freeze raise "Must set MXLEN for a configured config" if @mxlen.nil? end |
Instance Method Details
#fully_configured? ⇒ Boolean
305 |
# File 'lib/udb/config.rb', line 305 def fully_configured? = true |
#implemented_extensions ⇒ Array<Hash{String => String}>
314 315 316 317 318 319 320 321 322 323 324 325 326 327 |
# File 'lib/udb/config.rb', line 314 def implemented_extensions @implemented_extensions ||= if @data["implemented_extensions"].nil? [] else @data["implemented_extensions"].map do |e| if e.is_a?(Array) { "name" => e[0], "version" => e[1] } else e end end end end |
#mxlen ⇒ Integer
302 |
# File 'lib/udb/config.rb', line 302 def mxlen = @mxlen |
#param_values ⇒ Hash{String => ParamValueType}
ABSTRACT METHODS OVERRIDDEN #
299 |
# File 'lib/udb/config.rb', line 299 def param_values = @param_values |
#partially_configured? ⇒ Boolean
308 |
# File 'lib/udb/config.rb', line 308 def partially_configured? = false |
#unconfigured? ⇒ Boolean
311 |
# File 'lib/udb/config.rb', line 311 def unconfigured? = false |