Method: Satisfactory::Record#with_new

Defined in:
lib/satisfactory/record.rb

#with_new(count = nil, downstream_type, **attributes) ⇒ Satisfactory::Record, Satisfactory::Collection

Same as #with but always creates a new record.

Parameters:

  • count (Integer) (defaults to: nil)

    The number of records to create.

  • downstream_type (Symbol)

    The type of record to create.

  • attributes (Hash)

    The attributes to use when creating the record.

Returns:

Since:

  • 0.2.0



72
73
74
# File 'lib/satisfactory/record.rb', line 72

def with_new(count = nil, downstream_type, **attributes) # rubocop:disable Style/OptionalArguments
  with(count, downstream_type, force: true, **attributes)
end