Class: Restforce::DB::Strategies::Passive

Inherits:
Object
  • Object
show all
Defined in:
lib/restforce/db/strategies/passive.rb

Overview

Restforce::DB::Strategies::Passive defines an initialization strategy for a mapping in which newly-discovered records should never be synchronized into the other system. This strategy may be used to prevent multiple insertion points from existing for a single database record.

Instance Method Summary collapse

Constructor Details

#initialize(**_) ⇒ Passive

Public: Initialize a Restforce::DB::Strategies::Passive.



14
15
# File 'lib/restforce/db/strategies/passive.rb', line 14

def initialize(**_)
end

Instance Method Details

#build?(_) ⇒ Boolean

Public: Should the passed record be constructed in the other system?

Returns false.

Returns:

  • (Boolean)


20
21
22
# File 'lib/restforce/db/strategies/passive.rb', line 20

def build?(_)
  false
end

#passive?Boolean

Public: Is this a passive sync strategy?

Returns true.

Returns:

  • (Boolean)


27
28
29
# File 'lib/restforce/db/strategies/passive.rb', line 27

def passive?
  true
end