SwfdecAsRelay

SwfdecAsRelay — object for attaching to Actionscript objects

Functions

Types and Values

Object Hierarchy

    GObject
    ╰── SwfdecGcObject
        ╰── SwfdecAsRelay
            ╰── SwfdecAsFunction

Includes

#include <swfdec/swfdec.h>

Description

SwfdecAsRelay objects can be attached to a SwfdecAsObject using swfdec_as_object_relay(). You can then query an object for its relay in your own native function and use it there, for example by using SWFDEC_AS_CHECK().

Functions

swfdec_as_relay_call ()

gboolean
swfdec_as_relay_call (SwfdecAsRelay *relay,
                      const char *name,
                      guint argc,
                      SwfdecAsValue *argv,
                      SwfdecAsValue *return_value);

Calls the function named name on the given object. This function is essentially equal to the folloeing Actionscript code:

1
@return_value = @object.@name (@argv[0], ..., @argv[argc-1]);

Parameters

relay

a SwfdecAsRelay

 

name

garbage-collected string naming the function to call.

 

argc

number of arguments to provide to function

 

argv

arguments or NULL when argc is 0

 

return_value

location to take the return value of the call or NULL to ignore the return value.

 

Returns

TRUE if object had a function with the given name, FALSE otherwise


swfdec_as_relay_get_as_object ()

SwfdecAsObject *
swfdec_as_relay_get_as_object (SwfdecAsRelay *relay);

Gets the Actionscript object associated with this object.

Parameters

relay

a SwfdecAsRelay.

 

Returns

The SwfdecAsObject associated with this relay.

Types and Values

SwfdecAsRelay

typedef struct _SwfdecAsRelay SwfdecAsRelay;

This object has no public members.


struct SwfdecAsRelayClass

struct SwfdecAsRelayClass {
};

This is the base class for all objects that can be attached to a SwfdecAsObject. It has no virtual functions.