PcoCheckInsLocation class Null safety

This class represents a PCO CheckIns Location Object

Instantiation

  • This object cannot be created through the API.
  • Instantiate from existing JSON data using the PcoCheckInsLocation.fromJson() constructor.
  • Load an instance from the API using one of the static methods defined on this class.

Usage

  • Fields exposed by the API are readable through getter methods.
  • Fields writable by the API are exposed through setter methods.
  • Original json data is exposed through the read-only attributes map.
  • Additional data is available through the read-only links and relationships maps.
  • Available relationships / includes are exposed through typed getters.

Description

A place where people may check in to for a given event. Some locations have kind="Folder", which means that people can't check-in here, but this location contains other locations. You can get its contents from the locations attribute. You can get a location's parent folder from the parent attribute. (If it's not in a folder, parent will be empty.)

Attributes (and permissions)

  • id (ro) -> PCO: id
  • name (ro) -> PCO: name
  • kind (ro) -> PCO: kind
  • isOpened (ro) -> PCO: opened
  • questions (ro) -> PCO: questions
  • ageMinInMonths (ro) -> PCO: age_min_in_months
  • ageMaxInMonths (ro) -> PCO: age_max_in_months
  • ageRangeBy (ro) -> PCO: age_range_by
  • ageOn (ro) -> PCO: age_on
  • childOrAdult (ro) -> PCO: child_or_adult
  • effectiveDate (ro) -> PCO: effective_date
  • gender (ro) -> PCO: gender
  • gradeMin (ro) -> PCO: grade_min
  • gradeMax (ro) -> PCO: grade_max
  • maxOccupancy (ro) -> PCO: max_occupancy
  • minVolunteers (ro) -> PCO: min_volunteers
  • attendeesPerVolunteer (ro) -> PCO: attendees_per_volunteer
  • position (ro) -> PCO: position
  • updatedAt (ro) -> PCO: updated_at
  • createdAt (ro) -> PCO: created_at

Edges and Actions

Outbound Edges:

Inbound Edges:

Actions: NONE

Raw Data Object Example

{
  "type": "Location",
  "id": "1",
  "attributes": {
    "name": "string",
    "kind": "string",
    "opened": true,
    "questions": "string",
    "age_min_in_months": 1,
    "age_max_in_months": 1,
    "age_range_by": "string",
    "age_on": "2000-01-01",
    "child_or_adult": "string",
    "effective_date": "2000-01-01",
    "gender": "string",
    "grade_min": 1,
    "grade_max": 1,
    "max_occupancy": 1,
    "min_volunteers": 1,
    "attendees_per_volunteer": 1,
    "position": 1,
    "updated_at": "2000-01-01T12:00:00Z",
    "created_at": "2000-01-01T12:00:00Z"
  },
  "relationships": {
    "parent": {
      "data": {
        "type": "Parent",
        "id": "1"
      }
    }
  }
}
Inheritance

Constructors

PcoCheckInsLocation({String? id, String? name, String? kind, bool? isOpened, String? questions, int? ageMinInMonths, int? ageMaxInMonths, String? ageRangeBy, String? ageOn, String? childOrAdult, String? effectiveDate, String? gender, int? gradeMin, int? gradeMax, int? maxOccupancy, int? minVolunteers, int? attendeesPerVolunteer, int? position, DateTime? updatedAt, DateTime? createdAt, Map<String, List<PcoResource>>? withRelationships, List<PcoResource>? withIncluded})
Create a new PcoCheckInsLocation object. This object cannot be created with the API
factory
PcoCheckInsLocation.empty()
Create an empty instance of this class. This is only useful when an endpoint requires related or included data.
PcoCheckInsLocation.fromJson(Map<String, dynamic> data, {List<Map<String, dynamic>>? withIncluded})

Properties

ageMaxInMonths int
read-only
ageMinInMonths int
read-only
ageOn String
read-only
ageRangeBy String
read-only
api PlanningCenter
planning center resources must be tied to an api
read-onlyinherited
apiEndpoint String
read-onlyinherited
apiPath String
PcoResources include their own path as a link object but this might be null if we haven't created/fetched the object yet Child classes should redefine this getter to allow for manual path overrides
read-onlyoverride
apiVersion String
child classes can override these getters which will allow methods in this class to see static variables from child classes
read-onlyoverride
attendeesPerVolunteer int
read-only
attributes ReadOnlyMapView<String, dynamic>
contains the underlying attributes returned by the api and allows a user to access arbitrary data in the attributes by actual api name
read-onlyinherited
canCreate bool
read-onlyoverride
canDestroy bool
read-onlyoverride
canUpdate bool
read-onlyoverride
childOrAdult String
read-only
createAllowed List<String>
read-onlyoverride
createdAt DateTime
read-onlyinherited
createPathTemplate String
read-onlyoverride
defaultPathTemplate String
read-onlyoverride
effectiveDate String
read-only
fetched bool
indicate whether an item is full or partial
read / writeinherited
gender String
read-only
gradeMax int
read-only
gradeMin int
read-only
hashCode int
The hash code for this object.
read-onlyinherited
id String?
read-onlyinherited
included List<PcoResource>
contains included items parsed into objects
read-onlyinherited
includedEvent PcoCheckInsEvent?
read-only
includedLocations List<PcoCheckInsLocation>
read-only
includedOptions List<PcoCheckInsOption>
read-only
isOpened bool
read-only
kind String
read-only
contains the links data returned by the api if present
read-onlyinherited
maxOccupancy int
read-only
minVolunteers int
read-only
name String
read-only
needsSave bool
read-onlyinherited
pcoApplication String
latefinalinherited
position int
read-only
questions String
read-only
relationships ReadOnlyMapView<String, List<PcoResource>>
contains relationships parsed into objects even though the api sends relationship objects as Maps or Lists we always put them into lists for consistency
read-onlyinherited
resourceType String
all planning center resources must have a type
latefinalinherited
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
slug String
read-onlyinherited
updateAllowed List<String>
read-onlyoverride
updatedAt DateTime
read-onlyinherited

Methods

coerceDouble(dynamic a) double
inherited
coerceInt(dynamic a) int
inherited
delete() Future<PlanningCenterApiResponse<PlanningCenterApiData>>
inherited
filteredAttributes(List<String> allowedKeys) Map<String, dynamic>
inherited
fromJson(Map<String, dynamic> data, {List<Map<String, dynamic>>? withIncluded}) → dynamic
Takes a full JSON:API Response Object (the contents of a "data" field) will clear and update id, apiPath, attributes and _relationships
inherited
getCheckIns({PcoCheckInsCheckInQuery? query}) Future<PcoCollection<PcoCheckInsCheckIn>>
Will get a collection of PcoCheckInsCheckIn objects (expecting many) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/check_ins
getEvent({PcoCheckInsEventQuery? query}) Future<PcoCollection<PcoCheckInsEvent>>
Will get a collection of PcoCheckInsEvent objects (expecting many) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/event
getLocationEventPeriods({PcoCheckInsLocationEventPeriodQuery? query}) Future<PcoCollection<PcoCheckInsLocationEventPeriod>>
Will get a collection of PcoCheckInsLocationEventPeriod objects (expecting many) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/location_event_periods
getLocationEventTimes({PcoCheckInsLocationEventTimeQuery? query}) Future<PcoCollection<PcoCheckInsLocationEventTime>>
Will get a collection of PcoCheckInsLocationEventTime objects (expecting many) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/location_event_times
getLocationLabels({PcoCheckInsLocationLabelQuery? query}) Future<PcoCollection<PcoCheckInsLocationLabel>>
Will get a collection of PcoCheckInsLocationLabel objects (expecting many) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/location_labels
getLocations({PcoCheckInsLocationQuery? query}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a collection of PcoCheckInsLocation objects (expecting many) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/locations
getOptions({PcoCheckInsOptionQuery? query}) Future<PcoCollection<PcoCheckInsOption>>
Will get a collection of PcoCheckInsOption objects (expecting many) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/options
getParent({PcoCheckInsLocationQuery? query}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a collection of PcoCheckInsLocation objects (expecting one) using a path like this: https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations/1/parent
handleIncludes(List<Map<String, dynamic>> included) → void
This function populates the relationships with typed resource objects based on the data in the included map of the json.
inherited
handleItem(Map<String, dynamic> data) PcoResource?
inherited
handleRelationships(Map<String, dynamic> items, [List<Map<String, dynamic>> included = const []]) Map<String, List<PcoResource>>
inherited
includedParent<T extends PcoResource>() List<T>
The code generator could not automatically determine the resource type of this relationship. For type safe code, you should specify it in the type argument when calling.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
save({Map<String, PcoResource>? withRelated, List<PcoResource>? withIncluded}) Future<PlanningCenterApiResponse<PlanningCenterApiData>>
Many Planning Center endpoints allow or require additional relationships and/or included items to be sent with a create/update operation. Since these cannot always be determined by the automatic code generation, they may be included as arguments to the save operation.
inherited
toCreateResource() Map<String, dynamic>
create the attributes Map for this object without the id field using only the attributes allowed in create (post) operations
inherited
toDataMap({Map<String, PcoResource>? withRelated, List<PcoResource>? withIncluded}) Map<String, dynamic>
create a json-api Map for this object automatically selecting create or update based on the existence of the id field. Will result in something like this:
inherited
toIdResource() Map<String, dynamic>
returns the simplest representation of this resource with only the type and the id:
inherited
toJson({dynamic includeAttributes = true, dynamic includeRelationships = false}) Map<String, dynamic>
Some api requests only want the type and id of an object. In those cases, set includeAttributes to false or call toIdResource instead.
inherited
toString() String
A string representation of this object.
inherited
toUpdateResource() Map<String, dynamic>
create the attributes Map for this object using only the attributes allowed in update (patch) operations
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

canInclude List<String>
possible includes with parameter ?include=a,b
read-only
canOrderBy List<String>
possible orderings with parameter ?order=
read-only
canQuery List<String>
possible queries using parameters like ?wherekey=value or ?wheregt|lt=value
read-only

Static Methods

getAllFromCheckIn(String checkInId, {String? id, PcoCheckInsLocationQuery? query, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection containing ALL PcoCheckInsLocation objects (expecting many) using a path like this: /check-ins/v2/check_ins/$checkInId/locations
getAllFromCheckInAndLocation(String checkInId, String locationId, {String? id, PcoCheckInsLocationQuery? query, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection containing ALL PcoCheckInsLocation objects (expecting many) using a path like this: /check-ins/v2/check_ins/$checkInId/locations/$locationId/locations
getAllFromEvent(String eventId, {String? id, PcoCheckInsLocationQuery? query, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection containing ALL PcoCheckInsLocation objects (expecting many) using a path like this: /check-ins/v2/events/$eventId/locations
getAvailableLocationsFromEventTime(String eventTimeId, {PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting one) using a path like this: /check-ins/v2/event_times/$eventTimeId/available_locations
getFromCheckIn(String checkInId, {String? id, PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting many) using a path like this: /check-ins/v2/check_ins/$checkInId/locations
getFromCheckInAndEventPeriodAndLocationEventPeriod(String checkInId, String eventPeriodId, String locationEventPeriodId, {PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting one) using a path like this: /check-ins/v2/check_ins/$checkInId/event_period/$eventPeriodId/location_event_periods/$locationEventPeriodId/location
getFromCheckInAndLocation(String checkInId, String locationId, {String? id, PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting many) using a path like this: /check-ins/v2/check_ins/$checkInId/locations/$locationId/locations
getFromEvent(String eventId, {String? id, PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting many) using a path like this: /check-ins/v2/events/$eventId/locations
getFromEventTimeAndLocationEventTime(String eventTimeId, String locationEventTimeId, {PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting one) using a path like this: /check-ins/v2/event_times/$eventTimeId/location_event_times/$locationEventTimeId/location
getFromLabelAndLocationLabel(String labelId, String locationLabelId, {PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting one) using a path like this: /check-ins/v2/labels/$labelId/location_labels/$locationLabelId/location
getFromStation(String stationId, {PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting one) using a path like this: /check-ins/v2/stations/$stationId/location
getParentFromCheckInAndLocation(String checkInId, String locationId, {PcoCheckInsLocationQuery? query, bool getAll = false, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCollection<PcoCheckInsLocation>>
Will get a PcoCollection of PcoCheckInsLocation objects (expecting one) using a path like this: /check-ins/v2/check_ins/$checkInId/locations/$locationId/parent
getSingleFromCheckIn(String checkInId, String id, {PcoCheckInsLocationQuery? query, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCheckInsLocation?>
Will get a single PcoCheckInsLocation object using a path like this: /check-ins/v2/check_ins/$checkInId/locations/[id]
getSingleFromCheckInAndLocation(String checkInId, String locationId, String id, {PcoCheckInsLocationQuery? query, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCheckInsLocation?>
Will get a single PcoCheckInsLocation object using a path like this: /check-ins/v2/check_ins/$checkInId/locations/$locationId/locations/[id]
getSingleFromEvent(String eventId, String id, {PcoCheckInsLocationQuery? query, bool includeAllRelated = false, bool includeEvent = false, bool includeLocations = false, bool includeOptions = false, bool includeParent = false}) Future<PcoCheckInsLocation?>
Will get a single PcoCheckInsLocation object using a path like this: /check-ins/v2/events/$eventId/locations/[id]

Constants

kAgeMaxInMonths → const String
'age_max_in_months'
kAgeMinInMonths → const String
'age_min_in_months'
kAgeOn → const String
'age_on'
kAgeRangeBy → const String
'age_range_by'
kApiVersion → const String
'2019-07-17'
kAttendeesPerVolunteer → const String
'attendees_per_volunteer'
kChildOrAdult → const String
'child_or_adult'
kCreatedAt → const String
'created_at'
kCreatePathTemplate → const String
'null'
kDefaultPathTemplate → const String
'https://api.planningcenteronline.com/check-ins/v2/check_ins/1/locations'
kEffectiveDate → const String
'effective_date'
kGender → const String
'gender'
kGradeMax → const String
'grade_max'
kGradeMin → const String
'grade_min'
kId → const String
'id'
kKind → const String
'kind'
kMaxOccupancy → const String
'max_occupancy'
kMinVolunteers → const String
'min_volunteers'
kName → const String
'name'
kOpened → const String
'opened'
kPcoApplication → const String
'check-ins'
kPosition → const String
'position'
kQuestions → const String
'questions'
kTypeId → const String
'location'
kTypeString → const String
'Location'
kUpdatedAt → const String
'updated_at'