public interface AdminAction
SecuritySystem.runAsAdmin(AdminAction)
. All
external input should be carefully checked or even better copied
before being passed to this method. A common idiom would be:
public void someApiMethod(IObject target, String someValue)
{
AdminAction action = new AdminAction(){
public void runAsAdmin() {
IObject copy = iQuery.get( iObject.getClass(), iObject.getId() );
copy.setValue( someValue );
iUpdate.saveObject(copy);
}
};
}
SecuritySystem.runAsAdmin(AdminAction)
Modifier and Type | Method and Description |
---|---|
void |
runAsAdmin()
executes with special privileges within the
SecuritySystem . |
void runAsAdmin()
SecuritySystem
.SecuritySystem.runAsAdmin(AdminAction)
Version: 5.4.0-ice35-b74
Copyright © 2017 The University of Dundee & Open Microscopy Environment. All Rights Reserved.