Lattr(): Difference between revisions

From TinyMUX
Jump to navigation Jump to search
New page: Category:Functions {{Function|lattr(<object>[/<wild-pattern>])}} Returns a list of the attributes set on <object>. If <wild-pattern> is given, only attributes matching it are return...
 
No edit summary
 
Line 1: Line 1:
[[Category:Functions]]
== lattr() ==
 
;Syntax
: <code>lattr(&lt;object&gt;[/&lt;wild-pattern&gt;])</code>


{{Function|lattr(<object>[/<wild-pattern>])}}
;Summary
: Returns a space-separated list of attribute names on an object.


Returns a list of the attributes set on <object>. If <wild-pattern> is given, only attributes matching it are returned.
=== Parameters ===
* <code>&lt;object&gt;</code> — The object whose attributes are being queried.
* <code>&lt;wild-pattern&gt;</code> — Optional. A wildcard filter applied to attribute names.


== Example ==
=== Example ===
   
<pre>
> ex me
> ex me


     Mortal(#226Pc)
     Mortal(#226Pc)
 
     ...
     ....
 
     VC:Mon Sep  9 12:09:01 1991
     VC:Mon Sep  9 12:09:01 1991
     VE:baz
     VE:baz
     Last:Thu Dec 19 08:57:21 1991
     Last:Thu Dec 19 08:57:21 1991
     VV(#2+):Foof!
     VV(#2+):Foof!
     Domain:Abusees
     Domain:Abusees
 
     ...
     ....
 


> say lattr(me)
> say lattr(me)
You say, "Desc VC VE Last VV Domain"
You say, "Desc VC VE Last VV Domain"


> say lattr(me/v*)
> say lattr(me/v*)
You say, "VC VE VV"
You say, "VC VE VV"
</pre>


== Related Topics ==
=== See Also ===
* [[lattrp()]]
* [[attrcnt()]]
* [[@dolist]]


[[attrcnt()]], [[@dolist]], [[lattrp()]]
[[Category:Functions]]

Latest revision as of 11:53, 24 March 2025

lattr()

Syntax
lattr(<object>[/<wild-pattern>])
Summary
Returns a space-separated list of attribute names on an object.

Parameters

  • <object> — The object whose attributes are being queried.
  • <wild-pattern> — Optional. A wildcard filter applied to attribute names.

Example

> ex me

    Mortal(#226Pc)
    ...
    VC:Mon Sep  9 12:09:01 1991
    VE:baz
    Last:Thu Dec 19 08:57:21 1991
    VV(#2+):Foof!
    Domain:Abusees
    ...

> say lattr(me)
You say, "Desc VC VE Last VV Domain"

> say lattr(me/v*)
You say, "VC VE VV"

See Also