Show:

SaveOptions Class

Defined in: a55_saveOptions.js:6
Module: breeze

A SaveOptions instance is used to specify the 'options' under which a save will occur.

Methods

<ctor> SaveOptions

(
  • config
)

Parameters:

  • config Object
    • [allowConcurrentSaves] Boolean optional

      Whether multiple saves can be in-flight at the same time. The default is false.

    • [resourceName] String optional

      Resource name to be used during the save - this defaults to "SaveChanges"

    • [dataService] DataService optional

      The DataService to be used for this save.

    • [tag] Object optional

      Free form value that will be sent to the server during the save.

setAsDefault

() chainable

Sets the 'defaultInstance' by creating a copy of the current 'defaultInstance' and then applying all of the properties of the current instance. The current instance is returned unchanged.

using

(
  • config
)
chainable

Returns a copy of this SaveOptions with the specified config options applied.

Parameters:

  • config Configuration Object |

    The object to apply to create a new SaveOptions.

    • [allowConcurrentSaves] Boolean optional

      Whether multiple saves can be in-flight at the same time. The default is false.

    • [resourceName] String optional

      Resource name to be used during the save - this defaults to "SaveChanges"

    • [dataService] DataService optional

      The DataService to be used for this save.

    • [tag] Object optional

      Free form value that will be sent to the server during the save.

Example:

var saveOptions = em1.saveOptions.using( {resourceName: "anotherResource" });

Properties

allowConcurrentSaves

Boolean

Whether another save can be occuring at the same time as this one - default is false.

readOnly

dataService

DataService

A DataService. readOnly

defaultInstance

SaveOptions static

The default value whenever SaveOptions are not specified.

resourceName

String

The resource name to call to perform the save. readOnly

tag

Object

A free form value that will be sent to the server.

readOnly