Module: Jenkins::Plugin::Proxy::Marshal

Defined in:
lib/jenkins/plugin/proxy.rb

Overview

Make sure that proxy classes do not try to persist the plugin parameter. when serializing this proxy to XStream. It will be reconstructed with

Unmarshal#read_completed

Instance Method Summary collapse

Instance Method Details

#transient?(field) ⇒ Boolean

Tell XStream that we never want to persist the @plugin field

Parameters:

  • field (String)

    name of the field which xstream is enquiring about

Returns:

  • (Boolean)

    true if this is the plugin field, otherwise delegate



45
46
47
# File 'lib/jenkins/plugin/proxy.rb', line 45

def transient?(field)
  field.to_s == "plugin" or (super if defined? super)
end