Skip to contents

Base class for describing a resource.

Details

This is a base class for describing a resource on the platform: Projects, Tasks, Volumes, Files, Apps etc.

Public fields

auth

Seven Bridges Authentication object.

URL

List of URL endpoints for this resource.

Methods


Method new()

Create a new Resource object.

Usage

Resource$new(auth = NA)

Arguments

auth

Seven Bridges Authentication object.


Method query()

Generic query implementation that is used by the resources.

Usage

Resource$query(...)

Arguments

...

Parameters that will be passed to core api() function.


Method get()

Generic get implementation that fetches single resource from the server.

Usage

Resource$get(cls, id, ...)

Arguments

cls

Resource class object.

id

Object id.

...

Other arguments that can be passed to core api() function like 'fields', etc.


Method delete()

Generic implementation that deletes the resource from the server.

Usage

Resource$delete(id, ...)

Arguments

id

Object id.

...

Other arguments that can be passed to core api() function.

cls

Resource class object.


Method clone()

The objects of this class are cloneable with this method.

Usage

Resource$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.