summaryrefslogtreecommitdiff
path: root/perl/lib/Wallet/Object/Base.pm
diff options
context:
space:
mode:
authorBill MacAllister <whm@dropbox.com>2015-12-18 21:54:52 +0000
committerBill MacAllister <whm@dropbox.com>2015-12-18 21:54:52 +0000
commitf61bff40b0c76b01b89f8b977eb27fdef9409c2a (patch)
tree9812f0b1c38e001d6ddd8d7343adc40fa800e338 /perl/lib/Wallet/Object/Base.pm
parent0eb853eb2ef7e7063c0219ce2cbd1e239d5579b7 (diff)
parent4a777845b06b62a6deb1df5e69cc9b21226c3c2f (diff)
Merge branch 'master' into ad-keytabs
Conflicts: NEWS
Diffstat (limited to 'perl/lib/Wallet/Object/Base.pm')
-rw-r--r--perl/lib/Wallet/Object/Base.pm9
1 files changed, 9 insertions, 0 deletions
diff --git a/perl/lib/Wallet/Object/Base.pm b/perl/lib/Wallet/Object/Base.pm
index bdd61fb..97e6127 100644
--- a/perl/lib/Wallet/Object/Base.pm
+++ b/perl/lib/Wallet/Object/Base.pm
@@ -609,6 +609,15 @@ sub history {
# The get methods must always be overridden by the subclass.
sub get { die "Do not instantiate Wallet::Object::Base directly\n"; }
+# The update method should only work if a subclass supports it as something
+# different from get. That makes it explicit about whether the subclass has
+# a meaningful update.
+sub update {
+ my ($self) = @_;
+ $self->error ("update is not supported for this type, use get instead");
+ return;
+}
+
# Provide a default store implementation that returns an immutable object
# error so that auto-generated types don't have to provide their own.
sub store {