From 088e2ecba73fedebb0b7729a1f07022fd6155c22 Mon Sep 17 00:00:00 2001 From: Russ Allbery Date: Tue, 18 Sep 2007 23:40:37 +0000 Subject: Document the locked flag in the server backend and client man pages. Document locked flag issues when implementing a new object type. --- docs/design-api | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'docs') diff --git a/docs/design-api b/docs/design-api index 48c5a66..af2ff65 100644 --- a/docs/design-api +++ b/docs/design-api @@ -45,6 +45,10 @@ Object API administrator will want to destroy an orphaned wallet database entry after something happened to the remote system entry. + If you override this method and perform actions before calling the + parent method, be sure to check the locked flag first and abort if the + object is locked. + flag_clear(FLAG, PRINCIPAL, HOSTNAME [, DATETIME]) Normally, objects won't have to override this method, but if the @@ -68,6 +72,9 @@ Object API Don't forget to call log_action() after successfully retrieving the data to update the history and trace information. + Be sure to check the locked flag first and abort if the object is + locked before returning any data. + store(DATA, PRINCIPAL, HOSTNAME [, DATETIME]) Store user-supplied data into the given object. This may not be @@ -76,6 +83,9 @@ Object API storing data can just not implement this method and the default store() method will return an appropriate error. + Be sure to check the locked flag first and abort if the object is + locked without storing any data. + If this method is implemented, don't forget to call log_action() after successfully storing the data to update the history and trace information. -- cgit v1.2.3