Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Simple to call.
  • It creates the Response HTTP response Body and Content-Type Header automatically.

...

In many ways, GetObject and GetDatabaseItem are the same, including sharing many of the same arguments. GetObects differs from GetDatabaseItem in the following ways:

  • GetDatabaseItems returns GetDatabaseItem returns the resource object in serialized JSON (i.e., stringified JSON) whereas GetObject returns a handle to the JSON object.
  • GetDatabaseItems automatically GetDatabaseItem automatically updates the Response HTTP response Body with the resource object and the Content-Type Header whereas GetObject leaves this to the calling process to handle.
  • GetDatabaseItemsGetDatabaseItem will create a self and collection HATEOAS links in the resource object if the optional SelfURL argument is used whereas GetObject only creates a self HATEOAS link..
  • GetDatabaseItem does not do any error checking before it updates the HTTP response Body and the Content-Type Header where as GetObject performs a lot of error checking.

Since GetObject only returns a handle to the JSON object, it is the responsibility of the calling process to serialize the resource and update the HTTP response (e.g., Body, Content-Type Header, Status Code, etc.).This produces the following resource object: