147 |
@node Property Primitives |
@node Property Primitives |
148 |
@subsection Low Level Property Implementation. |
@subsection Low Level Property Implementation. |
149 |
|
|
150 |
@deffn {Scheme Procedure} primitive-make-property not_found_proc |
@deffn {Scheme Procedure} primitive-make-property not-found-proc |
151 |
@deffnx {C Function} scm_primitive_make_property (not_found_proc) |
@deffnx {C Function} scm_primitive_make_property (not_found_proc) |
152 |
Create a @dfn{property token} that can be used with |
Create a @dfn{property token} that can be used with |
153 |
@code{primitive-property-ref} and @code{primitive-property-set!}. |
@code{primitive-property-ref} and @code{primitive-property-set!}. |
154 |
See @code{primitive-property-ref} for the significance of |
See @code{primitive-property-ref} for the significance of |
155 |
@var{not_found_proc}. |
@var{not-found-proc}. |
156 |
@end deffn |
@end deffn |
157 |
|
|
158 |
@deffn {Scheme Procedure} primitive-property-ref prop obj |
@deffn {Scheme Procedure} primitive-property-ref prop obj |
159 |
@deffnx {C Function} scm_primitive_property_ref (prop, obj) |
@deffnx {C Function} scm_primitive_property_ref (prop, obj) |
160 |
Return the property @var{prop} of @var{obj}. When no value |
Return the property @var{prop} of @var{obj}. |
161 |
has yet been associated with @var{prop} and @var{obj}, call |
|
162 |
@var{not-found-proc} instead (see @code{primitive-make-property}) |
When no value has yet been associated with @var{prop} and @var{obj}, |
163 |
and use its return value. That value is also associated with |
the @var{not-found-proc} from @var{prop} is used. A call |
164 |
@var{obj} via @code{primitive-property-set!}. When |
@code{(@var{not-found-proc} @var{prop} @var{obj})} is made and the |
165 |
@var{not-found-proc} is @code{#f}, use @code{#f} as the |
result set as the property value. If @var{not-found-proc} is |
166 |
default value of @var{prop}. |
@code{#f} then @code{#f} is the property value. |
167 |
@end deffn |
@end deffn |
168 |
|
|
169 |
@deffn {Scheme Procedure} primitive-property-set! prop obj val |
@deffn {Scheme Procedure} primitive-property-set! prop obj val |
170 |
@deffnx {C Function} scm_primitive_property_set_x (prop, obj, val) |
@deffnx {C Function} scm_primitive_property_set_x (prop, obj, val) |
171 |
Associate @var{code} with @var{prop} and @var{obj}. |
Set the property @var{prop} of @var{obj} to @var{val}. |
172 |
@end deffn |
@end deffn |
173 |
|
|
174 |
@deffn {Scheme Procedure} primitive-property-del! prop obj |
@deffn {Scheme Procedure} primitive-property-del! prop obj |