OCLOperators canAccess
No edit summary
No edit summary
Line 1: Line 1:
The canAccess operator is available on objects and checks if this object can access a supplied [[ViewModel access and security|ViewModel]] based on the ViewModels Access Expression settings.
The canAccess operator is available on objects and checks if this object can access a supplied [[ViewModel access and security|ViewModel]] based on the ViewModels Access Expression settings.


Template
Template:
  self.canAccess(<name of viewmodel as string>)
  self.canAccess(<name of viewmodel as string>)
Example
Example:
  self.canAccess(User.ViewModels.UserSettings)
  self.canAccess(User.ViewModels.UserSettings)
In the example above we use the ViewModels operator to be sure that if the viewmodel name is changed, we get notified in the designer.
In the example above, we use the ViewModels operator to ensure that if the ViewModel name is changed, we get notified by the Designer.


====== See also ======
====== See also: ======
[[ViewModel access and security]]
[[ViewModel access and security]]


[[OCLOperators ViewModels]]
[[OCLOperators ViewModels]]


Keywords: viewmodel, access, security
Keywords: ViewModel, access, security
[[Category:OCLOperators]]
[[Category:OCLOperators]]
[[Category:OCL General Operators]]

Revision as of 06:46, 14 April 2023

The canAccess operator is available on objects and checks if this object can access a supplied ViewModel based on the ViewModels Access Expression settings.

Template:

self.canAccess(<name of viewmodel as string>)

Example:

self.canAccess(User.ViewModels.UserSettings)

In the example above, we use the ViewModels operator to ensure that if the ViewModel name is changed, we get notified by the Designer.

See also:

ViewModel access and security

OCLOperators ViewModels

Keywords: ViewModel, access, security

This page was edited 95 days ago on 02/10/2024. What links here