SDKPublishModel class
A model that represents the collection of published layouts.
This class also holds common data that is shared across all layouts.
- Inheritance
-
- Object
- PrivacyBase
- SDKPublishModel
- Available extensions
- Annotations
-
- @JsonSerializable.new()
Constructors
-
SDKPublishModel({required String projectId, SDKPublishUpdates? updates, List<
String> ? pages, Map<String, String> ? layoutIDMap, LookupMap<SDKPublishFont> ? fonts, LookupMap<SDKPublishLayout> ? layouts, LookupMap<SDKLayoutVariables> ? variables, LookupMap<SDKLayoutConditions> ? conditions, Map<String, HttpApiData> ? apis, String? entryLayoutId, String? entryPageId, String? entryCanvasId, DateTime? lastUpdated, List<String> ? disabledLayouts, required String owner, required Set<String> ? teams, required Set<String> ? users, required Map<String, Role> roles, required bool? public}) - Creates a new instance of SDKPublishModel.
-
SDKPublishModel.fromJson(Map<
String, dynamic> json) -
Creates a new instance of SDKPublishModel from a JSON map.
factory
-
SDKPublishModel.private({required String projectId, SDKPublishUpdates? updates, List<
String> ? pages, Map<String, String> ? layoutIDMap, Map<String, SDKPublishFont> ? fonts, Map<String, SDKPublishLayout> ? layouts, Map<String, SDKLayoutVariables> ? variables, Map<String, SDKLayoutConditions> ? conditions, Map<String, HttpApiData> ? apis, String? entryLayoutId, String? entryPageId, String? entryCanvasId, DateTime? lastUpdated, List<String> ? disabledLayouts, required PrivacyBase privacy}) - Creates a new instance of SDKPublishModel with privacy inherited from another PrivacyBase.
Properties
-
admins
→ Set<
String> -
An owner ID must always exist in the roles map. It's an error
if it doesn't.
no setterinherited
-
apis
→ Map<
String, HttpApiData> -
A map of apiId -> HttpApiData.
final
-
conditions
→ LookupMap<
SDKLayoutConditions> -
Contains information about the conditions used in the published project.
final
-
disabledLayouts
→ List<
String> -
A list of layout ids that are explicitly disabled from the server's side.
final
-
editors
→ List<
String> -
A list of user ids that are editors of this object.
no setterinherited
- entryCanvasId → String?
-
The id of the canvas that should be used as the entry point when viewing
from site.codelessly.com or the Codelessly template gallery.
final
- entryLayoutId → String?
-
The id of the layout that should be used as the entry point when viewing
from site.codelessly.com or the Codelessly template gallery.
final
- entryPageId → String?
-
The id of the page that should be used as the entry point when viewing
from site.codelessly.com or the Codelessly template gallery.
final
-
fonts
→ LookupMap<
SDKPublishFont> -
A lazily loaded map of fonts. This map is populated during initialization
of the SDK.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- lastUpdated → DateTime
-
final
-
layoutIDMap
→ Map<
String, String> -
This map is a map of CustomLayoutID -> OriginalLayoutID.
final
-
layouts
→ LookupMap<
SDKPublishLayout> -
A lazily loaded map of layouts. This map is populated during
initialization of the SDK.
final
- owner → String
-
The owner of the document. The owner is the user who is responsible for
the document and has the highest level of access to it. In terms of
permissions, it's equivalent to the Role.admin role, however this owner
is responsible for billing and other administrative tasks.
finalinherited
-
pages
→ List<
String> -
A list containing all of the pages that contain any of the layouts in
layouts map.
final
- privacy → PrivacyBase
-
While this PrivacyBase object is extended by other models, calling
toJson on those models will return data in addition to these core
privacy properties.
no setterinherited
- projectId → String
-
The project's id.
final
-
props
→ List<
Object?> -
The list of properties that will be used to determine whether
two instances are equal.
no setteroverride
- public → bool
-
Whether the object is public or not. If it is public, then
it is accessible to read by anyone on the platform.
finalinherited
-
roles
→ Map<
String, Role> -
The roles of each user from the users set.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stringify → bool?
-
If set to
true, thetoStringmethod will be overridden to output this instance'sprops.no setterinherited -
teams
→ Set<
String> -
The list of teams associated with a particular document.
finalinherited
- updates → SDKPublishUpdates
-
Contains information about the state of the published project.
This is used to determine whether fonts and layouts should be updated.
final
-
users
→ Set<
String> -
A set of user ids that are allowed to access the project in some way
defined by the roles map.
finalinherited
-
variables
→ LookupMap<
SDKLayoutVariables> -
Contains information about the variables used in the published project.
final
-
viewers
→ List<
String> -
A list of user ids that are viewers of this object.
no setterinherited
Methods
-
copyWith(
{String? projectId, List< String> ? pages, SDKPublishUpdates? updates, Map<String, String> ? layoutIDMap, Map<String, SDKPublishFont> ? fonts, Map<String, SDKPublishLayout> ? layouts, Map<String, HttpApiData> ? apis, Map<String, SDKLayoutVariables> ? variables, Map<String, SDKLayoutConditions> ? conditions, String? entryLayoutId, String? entryPageId, String? entryCanvasId, DateTime? lastUpdated, List<String> ? disabledLayouts, PrivacyBase? privacy}) → SDKPublishModel - Creates a copy of this instance with the provided parameters.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
resolveLayoutId(
String? id) → String? -
Available on SDKPublishModel, provided by the SDKPublishModelLayouts extension
The layoutidnames: a layout ID, or the ID of a canvas in a layout, so a link can open a screen by its canvas. Layouts not loaded yet (on another page, or loaded on demand) are found through SDKPublishUpdates.layoutCanvases. Null whenidis null or names neither. -
toFullJson(
) → Map< String, dynamic> - Converts this instance to a JSON map.
-
toJson(
) → Map< String, dynamic> - Converts this instance to a JSON map without the fonts, layouts, and apis.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
deserializeConditions(
Map json) → LookupMap< SDKLayoutConditions> -
deserializeFonts(
Map json) → LookupMap< SDKPublishFont> -
deserializeLayouts(
Map json) → LookupMap< SDKPublishLayout> -
deserializeLookupMap(
Map json) → Map< String, String> -
deserializeVariables(
Map json) → LookupMap< SDKLayoutVariables> -
readLookupMap(
Map json, String key) → Object? -
serializeLookupMapConditions(
LookupMap< SDKLayoutConditions> map) → Map<String, dynamic> -
serializeLookupMapFonts(
LookupMap< SDKPublishFont> map) → Map<String, dynamic> -
serializeLookupMapLayouts(
LookupMap< SDKPublishLayout> map) → Map<String, dynamic> -
serializeLookupMapVariables(
LookupMap< SDKLayoutVariables> map) → Map<String, dynamic>