BnNode Class Reference

#include <support/INode.h>

Inheritance diagram for BnNode:

INode BBinder IInterface IBinder SAtom SAtom BCatalogMirror BGenericNode BTokenSource BMetaDataNode BNodeDelegate BGenericCatalog BIndexedCatalog BIndexedDataNode BIndexedTableNode BSchemaRowIDJoin BSchemaRowIDJoin::RowNode BSchemaTableNode BCatalogDelegate List of all members.

Public Member Functions

virtual SValue Inspect (const sptr< IBinder > &caller, const SValue &which, uint32_t flags=0)
 Probe binder for interface information.
virtual sptr< IInterfaceInterfaceFor (const SValue &descriptor, uint32_t flags=0)
 Retrieve direct interface for this binder.
void PushAttributes (const sptr< INode > &value)
void PushCreationDate (nsecs_t value)
void PushEntryCreated (const sptr< INode > &who, const SString &name, const sptr< IBinder > &entry)
 This event is sent when a new entry appears in the node.
void PushEntryModified (const sptr< INode > &who, const SString &name, const sptr< IBinder > &entry)
 This event is sent when an entry in a catalog is modified.
void PushEntryRemoved (const sptr< INode > &who, const SString &name)
 This event is sent when an existing entry is removed from the node.
void PushEntryRenamed (const sptr< INode > &who, const SString &old_name, const SString &new_name, const sptr< IBinder > &entry)
 This event is sent when an entry in the catalog is renamed.
void PushMimeType (const SString &value)
void PushModifiedDate (nsecs_t value)
void PushNodeChanged (const sptr< INode > &who, uint32_t flags, const SValue &hints)
 This event is sent whenever some changes happens in the node.

Protected Member Functions

virtual sptr< const IBinderAsBinderImpl () const
virtual sptr< IBinderAsBinderImpl ()
 BnNode (const SContext &context)
 BnNode ()
virtual status_t HandleEffect (const SValue &, const SValue &, const SValue &, SValue *)
virtual status_t Transact (uint32_t code, SParcel &data, SParcel *reply, uint32_t flags)
 Low-level data transfer.
virtual ~BnNode ()

Constructor & Destructor Documentation

BnNode  )  [protected]
 

BnNode const SContext context  )  [protected]
 

virtual ~BnNode  )  [protected, virtual]
 


Member Function Documentation

virtual sptr<const IBinder> AsBinderImpl  )  const [protected, virtual]
 

Reimplemented from IInterface.

virtual sptr<IBinder> AsBinderImpl  )  [protected, virtual]
 

Reimplemented from IInterface.

virtual status_t HandleEffect const SValue ,
const SValue ,
const SValue ,
SValue
[protected, virtual]
 

Reimplemented from BBinder.

virtual SValue Inspect const sptr< IBinder > &  caller,
const SValue which,
uint32_t  flags = 0
[virtual]
 

Probe binder for interface information.

Return interfaces implemented by this binder object that are requested by which. This is a composition of all interfaces, expressed as { descriptor -> binder } mappings, which are selected through which.

Much more information on Inspect() can be found at Binder Inspect() Details.

Reimplemented from BBinder.

Reimplemented in BSchemaDatabaseNode, BSchemaRowIDJoin, BSchemaRowIDJoin::RowNode, BSchemaTableNode, BSchemaTableNode::RowNode, BCatalogDelegate, BIndexedDataNode, BIndexedTableNode, BGenericCatalog, BIndexedCatalog, BCatalogMirror, and BTokenSource.

virtual sptr<IInterface> InterfaceFor const SValue descriptor,
uint32_t  flags = 0
[virtual]
 

Retrieve direct interface for this binder.

Given a SValue interface descriptor, return an IInterface implementing it. The default implementation of this function returns NULL, meaning it does not implement a direct interface to it. If the return is non-NULL, you are guaranteed to be able to static_cast<> the returned interface into the requested subclass and have it work.

Note that this is NOT the same as calling Inspect(), which performs conversion between different IBinder objects. This method converts to an IInterface only for this binder object.

Reimplemented from BBinder.

void PushAttributes const sptr< INode > &  value  ) 
 

void PushCreationDate nsecs_t  value  ) 
 

void PushEntryCreated const sptr< INode > &  who,
const SString name,
const sptr< IBinder > &  entry
 

This event is sent when a new entry appears in the node.

Parameters:
[in] who The parent node in which this change occured.
[in] name The name of the entry that changed.
[in] entry The entry itself, usually either an INode or IDatum.
This informs you of a structural change to the node, where a new entry is appearing under it. The IBinder entry identifying the new entry is the same IBinder that is returned by Walk() and IIterator, and follows the same identity rules as defined for those APIs.

void PushEntryModified const sptr< INode > &  who,
const SString name,
const sptr< IBinder > &  entry
 

This event is sent when an entry in a catalog is modified.

Parameters:
[in] who The parent node in which this change occured.
[in] name The name of the entry that changed.
[in] entry The entry itself, either an INode or IDatum.
This informs you of a non-structural change to the node, where the data inside one of its items has changed. The IBinder entry identifying the changed entry is the same IBinder that is returned by Walk() and IIterator, and follows the same identity rules as defined for those APIs.

void PushEntryRemoved const sptr< INode > &  who,
const SString name
 

This event is sent when an existing entry is removed from the node.

Parameters:
[in] who The parent node in which this change occured.
[in] name The name of the entry that was removed.
This informs you of a structural change to the node, where an existing entry has been removed from it.

Todo:
Should this also return the IBinder of the old entry? For correctness, probably so, though that would cause some implementation difficulties.

void PushEntryRenamed const sptr< INode > &  who,
const SString old_name,
const SString new_name,
const sptr< IBinder > &  entry
 

This event is sent when an entry in the catalog is renamed.

Parameters:
[in] who The parent node in which this change occured.
[in] old_name The previous name of the entry.
[in] new_name The new name of the entry.
[in] entry The entry itself, either an INode or IDatum.
This informs you of a structural change to the node, where the name of one of its entries has changed. The IBinder entry identifying the renamed entry is the same IBinder that is returned by Walk() and IIterator, and follows the same identity rules as defined for those APIs.

Note:
This is NOT sent when an entry moves between different nodes! In that case you will get separate EntryCreated() and EntryRemoved() notifications from the two nodes.

void PushMimeType const SString value  ) 
 

void PushModifiedDate nsecs_t  value  ) 
 

void PushNodeChanged const sptr< INode > &  who,
uint32_t  flags,
const SValue hints
 

This event is sent whenever some changes happens in the node.

Parameters:
[in] who The node that has changed.
[in] flags Provides more information about the change.
[in] hints May provide even more info, but is currently unnused.
This event indicates that something has changed in the node, but not what that change is. If the node is not also pushing another change event (as indicated by the CHANGE_DETAILS_SENT flag), then you can't assuming anything about the current contents of the node.

virtual status_t Transact uint32_t  code,
SParcel data,
SParcel reply,
uint32_t  flags
[protected, virtual]
 

Low-level data transfer.

This is the Binder's IPC primitive. It allows you to send a parcel of data to another Binder (possibly in another process or language) and get a parcel of data back. The parcel can contain IBinder objects to transfer references between environments. The code can be any arbitrary value, though some standard codes are defined for parts of the higher-level IBinder protocol (B_EFFECT_TRANSACTION, B_INSPECT_TRANSACTION, etc). The flags are used for internal IPC implementation and must always be set to 0 when calling. If your implementation of Transact() returns an error code (instead of B_OK), that code will be propagated back to the caller WITHOUT any reply data.

Reimplemented from BBinder.


The documentation for this class was generated from the following file: