Squiz Matrix
4.12.2
|
Public Member Functions | |
__construct ($assetid=0) | |
_getName ($short_name=FALSE) | |
_getAllowedLinks () | |
getAsset ($shadowid, $type_code='', $mute_errors=FALSE) | |
getLinks ($assetid, $link_types, $type_code='', $strict_type_code=TRUE, $side_of_link='major', $sort_by=NULL) | |
getParents ($assetid, $type_code='', $strict_type_code=TRUE) | |
getChildren ($assetid, $type_code='', $strict_type_code=TRUE, $dependant=NULL, $sort_by=NULL) | |
getLineageFromURL ($assetid, $protocol, $url) | |
countLinks ($assetid, $side_of_link='major', $link_types=0, $type_code='', $strict_type_code=TRUE, $ignore_linkid=0) | |
deleteAssetLink ($linkid, $moving=FALSE) | |
getAssetMapLinks () | |
getAssetMapAssetInfo ($assetid) | |
prepareLink (Asset $asset, $side_of_link, &$link_type, &$value, &$sort_order, &$dependant, &$exclusive) | |
getStatus () | |
onAssetStatusUpdate (Asset $broadcaster, $event_vars) | |
readAccess (Array $assetids=Array()) | |
canCreateLink (Asset $minor, $link_type, $exclusive) | |
createLink (Asset $minor, $link_type, $value='', $sort_order=NULL, $dependant='0', $exclusive='0', $moving=FALSE) | |
getAllBundleStreams () | |
getAllBypassableBundleStreams () | |
isDefaultStreamBypassable () | |
Public Member Functions inherited from Asset | |
Asset ($assetid=0) | |
create (Array &$link) | |
load ($assetid) | |
_loadDataPaths () | |
reload () | |
canDelete () | |
delete ($release_lock=TRUE, $check_locked=TRUE) | |
useSystemVersion () | |
loadSystemVersion () | |
saveSystemVersion () | |
clearSystemVersion () | |
revertToSystemVersion () | |
revertNoticeLinksToSystemVersion () | |
_updated ($update_parents=TRUE) | |
type () | |
getTypeAncestors ($include_asset=TRUE) | |
incrementVersion ($number='micro', $update_parents=TRUE) | |
getLanguages () | |
setLanguages (Array $languages) | |
setCharset ($charset) | |
setForceSecure ($force_secure) | |
remapAssetids (Array $map) | |
morph ($new_type_code) | |
_morphCleanup ($new_type_code) | |
onRequestKeywords (Asset $broadcaster, Array $vars=Array()) | |
canClone () | |
cloneComponents (Asset $clone, Array $components, $override=FALSE) | |
cloneComponentsAdditional (Asset $clone, Array $components) | |
cloneLinks (Asset $clone) | |
getStatus () | |
getAvailableStatii () | |
getStatusDescription () | |
processStatusChange ($new_status, $update_parents=TRUE, $run_updated=TRUE) | |
setDate ($date_type, $time=NULL, $userid=NULL) | |
lockTypes () | |
canForceablyAcquireLock ($lock_type) | |
getEditingLocks ($keywords) | |
_getAllowedLinks () | |
createLink (Asset $minor, $link_type, $value='', $sort_order=NULL, $dependant='0', $exclusive='0', $moving=FALSE, $locked=0) | |
prepareLink (Asset $asset, $side_of_link, &$link_type, &$value, &$sort_order, &$dependant, &$exclusive) | |
canCreateLink (Asset $minor, $link_type, $exclusive) | |
canMoveLink (Asset $minor, Asset $old_major, $link_type) | |
describeLink ($linkid) | |
isDeletableLink ($linkid) | |
canDeleteLink ($linkid) | |
deleteLink ($linkid, $check_locked=TRUE) | |
linksUpdated () | |
canCloneLink () | |
saveAttributes ($dont_run_updated=FALSE, $log_message=TRUE) | |
setAttrValue ($name, $value) | |
attr ($name) | |
& | attrByRef ($name) |
getAttribute ($name, $mute_errors=FALSE) | |
getAssetKeywords ($descriptions=FALSE) | |
getAvailableKeywords () | |
getKeywordReplacement ($keyword) | |
getAssetWebPathKeywordReplacement () | |
getCustomKeywordReplacements ($keywords=Array(), $invoke_backend=FALSE) | |
processCustomKeywords ($keywords=Array()) | |
getContent () | |
setContent () | |
getEffectiveLastUpdatedTime ($assetids) | |
readAccess (Array $assetids=Array()) | |
writeAccess ($lock_type='', Array $assetids=Array(), $only_workflow=TRUE) | |
adminAccess ($lock_type='', Array $assetids=Array()) | |
backendAccess () | |
liveEditAccess ($lock_type) | |
canliveEdit ($lock_type) | |
effectiveUnrestricted () | |
checkAccess ($perm, $lock_type, Array $assetids=Array(), $only_workflow=TRUE) | |
accessEffective () | |
permissionsUpdated () | |
printFrontend () | |
printFrontendAsset (Asset $asset, $design=NULL) | |
getValidProtocols () | |
printHead () | |
printBody () | |
getCurrentPaintLayoutName () | |
getCurrentDesignName () | |
printBodyWithPaintLayout ($layout_id='') | |
initLimbo () | |
printLimbo () | |
paintBackend (Backend_Outputter $o) | |
getPrefix () | |
processBackend (Backend_Outputter $o, Array &$link) | |
getEI () | |
getEditFns () | |
getBackendHref ($screen='', $backend_page=TRUE) | |
getURL ($base_url=NULL, $ignore_rollback=FALSE, $base_contextid=NULL) | |
getURLs () | |
getHref ($base_url=NULL, $ignore_rollback=FALSE) | |
getWebDataPath () | |
getWebPaths () | |
saveWebPaths ($paths, $auto_add_remaps=TRUE) | |
getLookups ($field='') | |
getDesignLookups () | |
getLookupValues ($inherited=NULL, $prefix='', $like_search=TRUE, $ignore_override=FALSE) | |
deleteLookupValue ($layout_name, $layout_value) | |
setPaintLayouts ($layouts) | |
updateLookups ($auto_add_remaps=TRUE) | |
setLookupValues (Array $values) | |
getAssetStatusDescriptionKeywordReplacement () | |
getAssetStatusColourKeywordReplacement () | |
replaceKeywordsInString ($string) | |
fastTrack ($tasks) | |
unFastTrack ($tasks) | |
shouldFastTrack ($task, $assetid=NULL) | |
getFaskTrackedTaskAssetids ($task) | |
getDependantParentsURL () | |
Public Member Functions inherited from MySource_Object | |
MySource_Object () | |
__sleep () | |
__wakeup () | |
Additional Inherited Members | |
Data Fields inherited from Asset | |
$id = 0 | |
$version = '' | |
$name = '' | |
$short_name = '' | |
$status | |
$languages = '' | |
$charset = '' | |
$force_secure = '0' | |
$created | |
$created_userid | |
$updated | |
$updated_userid | |
$published | |
$published_userid | |
$status_changed | |
$status_changed_userid | |
$_is_cacheable = FALSE | |
$vars = Array() | |
$_available_keywords = Array() | |
$data_path_suffix = '' | |
$data_path = '' | |
$data_path_public = '' | |
$_ser_attrs = FALSE | |
Protected Member Functions inherited from Asset | |
_preCreateCheck (Array &$link) | |
_createAdditional (Array &$link) | |
_abortCreate ($trigger_level_changed=FALSE, $linkid=0) | |
_loadVars () | |
_getName ($short_name=FALSE, $contextid=NULL) | |
_getKeywordReplacement ($keyword) | |
_checkPermissionAccess ($perm, $assetids=Array(), $only_workflow=TRUE) | |
makeAndSaveInitialWebPath ($path, $parent_link=NULL) | |
Definition at line 35 of file workflow_bundle.inc.
__construct | ( | $assetid = 0 | ) |
Constructor
int | $assetid | the asset id to be loaded |
Definition at line 45 of file workflow_bundle.inc.
_getAllowedLinks | ( | ) |
Returns an array of all the permitted links type, the type asset and the cardinality
Definition at line 74 of file workflow_bundle.inc.
_getName | ( | $short_name = FALSE | ) |
Returns the name of the asset
boolean | $short_name | TRUE = return short name; FALSE = return full name |
Definition at line 60 of file workflow_bundle.inc.
canCreateLink | ( | Asset | $minor, |
$link_type, | |||
$exclusive | |||
) |
Returns TRUE if the passed minor asset can be linked to this asset, or a string with the error msg
Asset | $minor | the minor asset that we are linking to |
string | $link_type | the type of link this is |
int | $exclusive | the exclusive status of the link (gets passed to canLinkToType) |
Definition at line 601 of file workflow_bundle.inc.
countLinks | ( | $assetid, | |
$side_of_link = 'major' , |
|||
$link_types = 0 , |
|||
$type_code = '' , |
|||
$strict_type_code = TRUE , |
|||
$ignore_linkid = 0 |
|||
) |
Return the number of links in the system that involve the specified asset
Can be restricted by either link type and/or asset type code
int | $assetid | id of the the $side_of_link asset |
string | $side_of_link | Which side of the link this (the current) asset is on ('major' or 'minor') |
int | $link_types | integer that can be the product of bitwise operations on the SQ_LINK_* constants |
mixed | $type_code | the type of asset that is linked (eg 'Page', 'File', etc) (can be a string or an array of strings) if an array returns link if matches any of the array values |
boolean | $strict_type_code | whether we are finding assets that are just a $type_code or $type_code and any of it's sub-classes |
int | $ignore_linkid | ignore the link represented by this link id when returning the count |
Implements Bridge.
Definition at line 232 of file workflow_bundle.inc.
createLink | ( | Asset | $minor, |
$link_type, | |||
$value = '' , |
|||
$sort_order = NULL , |
|||
$dependant = '0' , |
|||
$exclusive = '0' , |
|||
$moving = FALSE |
|||
) |
Creates a link between this asset and the passed asset, of a certain type and returns the linkid of the created link
Asset | $minor | the minor asset that we are linking to |
string | $link_type | the type of link this is |
string | $value | the value that is to be associated with this link |
string | $sort_order | the position in the links list that this link should take, if NULL or less than zero places at end of list |
string | $dependant | '0' / '1' on whether the this asset is dependant on the asset that will be linked by this new link |
string | $exclusive | '0' / '1' on whether the this asset is linked exclusivly to the asset that will be linked by this new link |
boolean | $moving | moving |
Definition at line 635 of file workflow_bundle.inc.
deleteAssetLink | ( | $linkid, | |
$moving = FALSE |
|||
) |
Remove a link by id
int | $linkid | the link id of the link to remove |
boolean | $moving | TRUE if this delete is part of a move operation |
Implements Bridge.
Definition at line 248 of file workflow_bundle.inc.
getAllBundleStreams | ( | ) |
Returns all available workflow streams in bundled assets, EXCEPT default streams
Array is of (stream_assetid => stream name)
Definition at line 657 of file workflow_bundle.inc.
getAllBypassableBundleStreams | ( | ) |
Returns all available workflow streams in bundled assets that would be bypassable in ALL of our bundled assets
Definition at line 692 of file workflow_bundle.inc.
getAsset | ( | $shadowid, | |
$type_code = '' , |
|||
$mute_errors = FALSE |
|||
) |
Returns a reference to the asset represented by the passed assetid
Nothing doing here. We aren't providing shadow assets to y'all, so go away.
int | $shadowid | the shadow part asset id to be loaded (i.e part after the ':') |
string | $type_code | if this exists then this object is used to load the asset, if not then the DB is queried to find out the asset type |
boolean | $mute_errors | stops the outputting of errors in this fn, needed because you can't use the '@' operator when returning by reference |
Implements Bridge.
Definition at line 104 of file workflow_bundle.inc.
getAssetMapAssetInfo | ( | $assetid | ) |
Get asset info for use by asset map
Should return an array containing the following elements:
web_path: Web path for this lineage of the asset, if known.
string | $assetid | Full Asset id to get information for |
Implements Bridge.
Definition at line 342 of file workflow_bundle.inc.
getAssetMapLinks | ( | ) |
Used by asset map to return a asset map-style link array
We need to implement this so our NOTICE links are shown in the asset map.
Definition at line 264 of file workflow_bundle.inc.
getChildren | ( | $assetid, | |
$type_code = '' , |
|||
$strict_type_code = TRUE , |
|||
$dependant = NULL , |
|||
$sort_by = NULL |
|||
) |
Get all asset ids that are below the passed assetid in the various trees in which it exists
Returns an array of assetids and their type code
I believe that this relates to structural links underneath us (cf. Search Folder). So this should be empty no matter what, since we only have NOTICE links.
int | $assetid | the id of the asset to get its children for |
mixed | $type_code | the type of asset that is linked (eg 'Page', 'File', etc) if an array returns link if matches any of the array values |
boolean | $strict_type_code | whether we are finding assets that are just a $type_code or $type_code and any of it's sub-classes |
boolean | $dependant | if TRUE, results will be filtered to assets that are dependants. If FALSE, results will all not be dependants. If NULL, results will not be filtered |
string | $sort_by | a field in the asset table you would like the results sorted by (eg. name, short_name etc) |
Implements Bridge.
Definition at line 185 of file workflow_bundle.inc.
getLineageFromURL | ( | $assetid, | |
$protocol, | |||
$url | |||
) |
Returns an array of assetid's + info in the order that they propogate out from THIS BRIDGE'S url
No URLs to propagate here, since we have no structural links that we need to provide lookups for.
string | $assetid | the id of the last asset in the lineage |
string | $protocol | the protocol to match -> NULL means it is ignored |
string | $url | the url to check for -> NULL defaults it to current url |
Implements Bridge.
Definition at line 205 of file workflow_bundle.inc.
getLinks | ( | $assetid, | |
$link_types, | |||
$type_code = '' , |
|||
$strict_type_code = TRUE , |
|||
$side_of_link = 'major' , |
|||
$sort_by = NULL |
|||
) |
Return all links that this asset has to other assets
int | $assetid | id of the the $side_of_link asset |
int | $link_types | integer that can be the product of bitwise operations on the SQ_LINK_* constants |
mixed | $type_code | the type of asset that is linked (eg 'Page', 'File', etc) if an array returns link if matches any of the array values |
boolean | $strict_type_code | whether we are finding assets that are just a $type_code or $type_code and any of it's sub-classes |
string | $side_of_link | Which side of the link this (the current) asset is on ('major' or 'minor') |
string | $sort_by | a field in the asset table you would like the results sorted by (eg. name, short_name etc) |
Implements Bridge.
Definition at line 132 of file workflow_bundle.inc.
getParents | ( | $assetid, | |
$type_code = '' , |
|||
$strict_type_code = TRUE |
|||
) |
Get all asset ids that are above the passed assetid in the various trees in which it exists
int | $assetid | the id of the asset to get its parents for |
mixed | $type_code | the type of asset that is linked (eg 'User', 'User_Group', etc) if an array returns link if matches any of the array values |
boolean | $strict_type_code | whether we are finding assets that are just a $type_code or $type_code and any of it's sub-classes |
Implements Bridge.
Definition at line 152 of file workflow_bundle.inc.
getStatus | ( | ) |
Returns a status object for the current asset to be used for processing
This is generally the same as the method in Asset itself, bar the subtle difference of it getting one of the Bundle status objects instead.
Definition at line 413 of file workflow_bundle.inc.
isDefaultStreamBypassable | ( | ) |
Is the default stream of all bundled assets bypassable?
Definition at line 716 of file workflow_bundle.inc.
onAssetStatusUpdate | ( | Asset | $broadcaster, |
$event_vars | |||
) |
Event listener for bundled assets cancelling their workflow
If any asset is rejected, any other bundled asset in workflow should be rolled back, as well as the bundle itself.
Note: status changes to the bundle are done with status integrity turned off because a normal user could not actually do these changes. Once the last asset with workflow is completed, the user then has no access to status changes.
Asset | $broadcaster | The broadcasting asset |
array | $event_vars | Any event variables sent by the broadcaster |
Definition at line 444 of file workflow_bundle.inc.
prepareLink | ( | Asset | $asset, |
$side_of_link, | |||
& | $link_type, | ||
& | $value, | ||
& | $sort_order, | ||
& | $dependant, | ||
& | $exclusive | ||
) |
Prepares for linking by checking that the link values are valid for this link
This function will be called if this asset is the major or minor party in the link, so the side_of_link flag should be checked to work out what side of the link this asset is on. The return value should indicate if any of the link fields were changed.
Asset | $asset | the major or minor asset that we are linking to |
string | $side_of_link | the side of the link we are on (major or minor) |
string | &$link_type | the type of link we are creating |
string | &$value | the value that is to be associated with the link |
string | &$sort_order | the position in the links list that this link should take, |
string | &$dependant | '0' / '1' on whether the this asset is dependant on the asset that will be linked by the new link |
string | &$exclusive | '0' / '1' on whether the this asset is linked exclusivly to the asset that will be linked by the new link |
Definition at line 390 of file workflow_bundle.inc.
readAccess | ( | Array | $assetids = Array() | ) |
Returns TRUE if at least one of the passed assetids has read access to this asset
array | $assetids | An array of user_group and/or user ids to check for read access If the array is empty, the current user will be checked |
Definition at line 570 of file workflow_bundle.inc.