diff options
author | Gianni Ceccarelli <gianni.ceccarelli@broadbean.com> | 2023-07-27 16:05:41 +0100 |
---|---|---|
committer | Gianni Ceccarelli <gianni.ceccarelli@broadbean.com> | 2023-07-27 16:11:10 +0100 |
commit | 8e235105c5d98c4daa431c12f2136f89eaeb128d (patch) | |
tree | 744db4c3201035db243d5cf957ef6c24d643bc50 /bos-meta-attribute.sh | |
parent | more flexible namespaced stores (diff) | |
download | bash-object-system-8e235105c5d98c4daa431c12f2136f89eaeb128d.tar.gz bash-object-system-8e235105c5d98c4daa431c12f2136f89eaeb128d.tar.bz2 bash-object-system-8e235105c5d98c4daa431c12f2136f89eaeb128d.zip |
vaguely bootstrap things?
Diffstat (limited to 'bos-meta-attribute.sh')
-rw-r--r-- | bos-meta-attribute.sh | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/bos-meta-attribute.sh b/bos-meta-attribute.sh index 78c573e..b5155ad 100644 --- a/bos-meta-attribute.sh +++ b/bos-meta-attribute.sh @@ -6,12 +6,13 @@ function bos/meta/attribute/store-for-into() { local bos_meta_attribute_class bos_meta_attribute_objid bos-object/unpack-self-into bos_meta_attribute_class bos_meta_attribute_objid "$2" - "bos-namespaces/${attribute_type}-store-for-into" "$1" attribute "$attribute_name" "$associated_class" "$bos_meta_attribute_class" "$bos_meta_attribute_objid" + "bos-namespaces/store-${attribute_type}-for-into" "$1" attribute "$attribute_name" "$associated_class" "$bos_meta_attribute_class" "$bos_meta_attribute_objid" } function bos/meta/attribute/set-value() { - local bos_meta_attribute_store; $self store-for-into bos_meta_attribute_store "$1" + local bos_meta_attribute_store_name; $self store-for-into bos_meta_attribute_store_name "$1" shift + local -n bos_meta_attribute_store="$bos_meta_attribute_store_name" case "$attribute_type" in scalar) bos_meta_attribute_store="$1" ;; @@ -25,7 +26,8 @@ function bos/meta/attribute/set-value() { function bos/meta/attribute/get-value-into() { local -n bos_meta_attribute_result="$1"; shift; - local bos_meta_attribute_store; $self store-for-into bos_meta_attribute_store "$1" + local bos_meta_attribute_store_name; $self store-for-into bos_meta_attribute_store_name "$1" + local -n bos_meta_attribute_store="$bos_meta_attribute_store_name" case "$attribute_type" in scalar) bos_meta_attribute_result="$bos_meta_attribute_store" ;; @@ -35,4 +37,3 @@ function bos/meta/attribute/get-value-into() { return 0 } - |