LLVM 23.0.0git
llvm::cas::NamedValuesSchema Class Reference

A schema for representing an array of named nodes in a CAS. More...

#include "llvm/CAS/NamedValuesSchema.h"

Inheritance diagram for llvm::cas::NamedValuesSchema:
[legend]

Classes

class  Builder
 A builder class for creating nodes in NamedValuesSchema. More...

Public Member Functions

bool isRootNode (const ObjectProxy &Node) const final
bool isNode (const ObjectProxy &Node) const final
 Check if a proxy represents a valid node.
Expected< NamedValuesProxyload (ObjectRef Object) const
 Load NamedValuesProxy from an ObjectRef.
Expected< NamedValuesProxyload (ObjectProxy Object) const
 Load NamedValuesProxy from an ObjectProxy.
Expected< NamedValuesProxyconstruct (ArrayRef< NamedValuesEntry > Entries)
 Construct a NamedValuesSchema CAS object with the given entries.
Public Member Functions inherited from llvm::RTTIExtends< NamedValuesSchema, NodeSchema >
const void * dynamicClassID () const override
bool isA () const
 Check whether this instance is a subclass of QueryT.

Static Public Member Functions

static Expected< NamedValuesSchemacreate (ObjectStore &CAS)
 Create a NamedValuesSchema.
Static Public Member Functions inherited from llvm::RTTIExtends< NamedValuesSchema, NodeSchema >
static const void * classID ()
static bool classof (const T *R)

Static Public Attributes

static char ID = 0

Friends

class NamedValuesProxy

Detailed Description

A schema for representing an array of named nodes in a CAS.

The name of the nodes are stored in the root node so child node can be loaded on demand based on name and the name for all nodes need to be unique.

Definition at line 49 of file NamedValuesSchema.h.

Member Function Documentation

◆ construct()

◆ create()

Expected< NamedValuesSchema > NamedValuesSchema::create ( ObjectStore & CAS)
static

◆ isNode()

bool NamedValuesSchema::isNode ( const ObjectProxy & Node) const
final

Check if a proxy represents a valid node.

Definition at line 22 of file NamedValuesSchema.cpp.

Referenced by isRootNode(), and load().

◆ isRootNode()

bool llvm::cas::NamedValuesSchema::isRootNode ( const ObjectProxy & Node) const
inlinefinal

Definition at line 56 of file NamedValuesSchema.h.

References isNode().

◆ load() [1/2]

Expected< NamedValuesProxy > NamedValuesSchema::load ( ObjectProxy Object) const

◆ load() [2/2]

Expected< NamedValuesProxy > NamedValuesSchema::load ( ObjectRef Object) const

Load NamedValuesProxy from an ObjectRef.

Definition at line 106 of file NamedValuesSchema.cpp.

References llvm::cas::ObjectStore::getProxy(), and load.

◆ NamedValuesProxy

friend class NamedValuesProxy
friend

Definition at line 94 of file NamedValuesSchema.h.

References E(), I, and NamedValuesProxy.

Referenced by construct(), load(), and NamedValuesProxy.

Member Data Documentation

◆ ID

char NamedValuesSchema::ID = 0
static

Definition at line 54 of file NamedValuesSchema.h.


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