LLVM API Documentation

Public Types | Public Member Functions | Static Public Member Functions
llvm::MDString Class Reference

A single uniqued string. More...

#include <Metadata.h>

Inheritance diagram for llvm::MDString:
Inheritance graph
Collaboration diagram for llvm::MDString:
Collaboration graph

List of all members.

Public Types

typedef StringRef::iterator iterator

Public Member Functions

StringRef getString () const
unsigned getLength () const
iterator begin () const
 Pointer to the first byte of the string.
iterator end () const
 Pointer to one byte past the end of the string.

Static Public Member Functions

static MDStringget (LLVMContext &Context, StringRef Str)
static MDStringget (LLVMContext &Context, const char *Str)
static bool classof (const Value *V)
 Methods for support type inquiry through isa, cast, and dyn_cast.

Detailed Description

A single uniqued string.

These are used to efficiently contain a byte sequence for metadata. MDString is always unnamed.

Definition at line 42 of file Metadata.h.

Member Typedef Documentation

Definition at line 57 of file Metadata.h.

Member Function Documentation

iterator llvm::MDString::begin ( ) const [inline]

Pointer to the first byte of the string.

Definition at line 60 of file Metadata.h.

References llvm::StringRef::begin(), and llvm::Value::getName().

static bool llvm::MDString::classof ( const Value V) [inline, static]

Methods for support type inquiry through isa, cast, and dyn_cast.

Definition at line 66 of file Metadata.h.

References llvm::Value::getValueID(), and llvm::Value::MDStringVal.

iterator llvm::MDString::end ( ) const [inline]

Pointer to one byte past the end of the string.

Definition at line 63 of file Metadata.h.

References llvm::StringRef::end(), and llvm::Value::getName().

MDString * MDString::get ( LLVMContext Context,
StringRef  Str 
) [static]
static MDString* llvm::MDString::get ( LLVMContext Context,
const char *  Str 
) [inline, static]

Definition at line 49 of file Metadata.h.

unsigned llvm::MDString::getLength ( ) const [inline]

Definition at line 55 of file Metadata.h.

References llvm::Value::getName(), and llvm::StringRef::size().

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