PcoCalendarResourceQuery constructor
PcoCalendarResourceQuery({
- bool includeResourceApprovalGroups = false,
- bool includeResourceFolder = false,
- bool includeResourceQuestions = false,
- bool includeRoomSetups = false,
- bool includeAllRelated = false,
- String? whereCreatedAt,
- String? whereKind,
- String? whereName,
- String? wherePathName,
- String? whereSerialNumber,
- String? whereUpdatedAt,
- PcoCalendarResourceFilter? filterBy,
- PcoCalendarResourceOrder? orderBy,
- bool reverse = false,
- int perPage = 25,
- int pageOffset = 0,
- Map<
String, String> extraParams = const {}, - List<
PlanningCenterApiWhere> ? where, - Iterable<
String> filter = const <String>[], - String? order,
- Iterable<
String> include = const <String>[],
Implementation
PcoCalendarResourceQuery({
/// include associated resource_approval_groups
/// when true, adds `?include=resource_approval_groups` to url
bool includeResourceApprovalGroups = false,
/// include associated resource_folder
/// when true, adds `?include=resource_folder` to url
bool includeResourceFolder = false,
/// include associated resource_questions
/// when true, adds `?include=resource_questions` to url
bool includeResourceQuestions = false,
/// include associated room_setups
/// when true, adds `?include=room_setups` to url
bool includeRoomSetups = false,
/// when true, adds `?include=resource_approval_groups,resource_folder,resource_questions,room_setups` to url parameters
bool includeAllRelated = false,
/// Query by `created_at`
/// query on a specific created_at, url example: ?where[created_at]=2000-01-01T12:00:00Z
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereCreatedAt,
/// Query by `kind`
/// query on a specific kind, url example: ?where[kind]=string
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereKind,
/// Query by `name`
/// query on a specific name, url example: ?where[name]=string
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereName,
/// Query by `path_name`
/// query on a specific path_name, url example: ?where[path_name]=string
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? wherePathName,
/// Query by `serial_number`
/// query on a specific serial_number, url example: ?where[serial_number]=string
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereSerialNumber,
/// Query by `updated_at`
/// query on a specific updated_at, url example: ?where[updated_at]=2000-01-01T12:00:00Z
/// include a prefix of `<`, `<=`, `>`, `>=` to query by comparisons
String? whereUpdatedAt,
PcoCalendarResourceFilter? filterBy,
PcoCalendarResourceOrder? orderBy,
/// reverse the ordering
bool reverse = false,
// direct access to super class params
super.perPage,
super.pageOffset,
super.extraParams,
super.where,
super.filter,
super.order,
super.include,
}) : super() {
if (filterBy != null) filter.add(filterString(filterBy));
if (includeAllRelated || includeResourceApprovalGroups)
include.add('resource_approval_groups');
if (includeAllRelated || includeResourceFolder)
include.add('resource_folder');
if (includeAllRelated || includeResourceQuestions)
include.add('resource_questions');
if (includeAllRelated || includeRoomSetups) include.add('room_setups');
if (whereCreatedAt != null)
where.add(PlanningCenterApiWhere.parse('created_at', whereCreatedAt));
if (whereKind != null)
where.add(PlanningCenterApiWhere.parse('kind', whereKind));
if (whereName != null)
where.add(PlanningCenterApiWhere.parse('name', whereName));
if (wherePathName != null)
where.add(PlanningCenterApiWhere.parse('path_name', wherePathName));
if (whereSerialNumber != null)
where.add(
PlanningCenterApiWhere.parse('serial_number', whereSerialNumber));
if (whereUpdatedAt != null)
where.add(PlanningCenterApiWhere.parse('updated_at', whereUpdatedAt));
if (orderBy != null) order = orderString(orderBy, reverse: reverse);
}