Handbook
Glossary
set-ref ( obj ref -- )
Factor handbook
»
The language
»
Collections
»
References
»
Reference protocol
Prev:
get-ref ( ref -- obj )
Next:
delete-ref ( ref -- )
Vocabulary
refs
Inputs
obj
an
object
ref
a
ref
Outputs
None
Word description
Stores a new value at this reference.
See also
get-ref
,
set-ref*
Definition
IN:
refs
GENERIC:
set-ref
( obj ref -- )
Methods
USING:
boxes
refs
;
M:
box
set-ref
>box
;
USING:
accessors
namespaces
refs
;
M:
global-var-ref
set-ref
var>>
set-global
;
USING:
assocs
refs
;
M:
key-ref
set-ref
>assoc-ref<
rename-at
;
USING:
accessors
refs
;
M:
obj-ref
set-ref
obj<<
;
USING:
refs
slots.private
;
M:
slot-ref
set-ref
>slot-ref<
set-slot
;
USING:
assocs
refs
;
M:
value-ref
set-ref
>assoc-ref<
set-at
;
USING:
accessors
namespaces
refs
;
M:
var-ref
set-ref
var>>
set
;