clang 19.0.0git
Public Member Functions | Friends | List of all members
clang::api_notes::ObjCContextInfo Class Reference

Describes API notes data for an Objective-C class or protocol. More...

#include "clang/APINotes/Types.h"

Inheritance diagram for clang::api_notes::ObjCContextInfo:
Inheritance graph
[legend]

Public Member Functions

 ObjCContextInfo ()
 
std::optional< NullabilityKindgetDefaultNullability () const
 Determine the default nullability for properties and methods of this class.
 
void setDefaultNullability (NullabilityKind Kind)
 Set the default nullability for properties and methods of this class.
 
bool hasDesignatedInits () const
 
void setHasDesignatedInits (bool Value)
 
std::optional< boolgetSwiftImportAsNonGeneric () const
 
void setSwiftImportAsNonGeneric (std::optional< bool > Value)
 
std::optional< boolgetSwiftObjCMembers () const
 
void setSwiftObjCMembers (std::optional< bool > Value)
 
void stripModuleLocalInfo ()
 Strip off any information within the class information structure that is module-local, such as 'audited' flags.
 
ObjCContextInfooperator|= (const ObjCContextInfo &RHS)
 
LLVM_DUMP_METHOD void dump (llvm::raw_ostream &OS)
 
- Public Member Functions inherited from clang::api_notes::CommonTypeInfo
 CommonTypeInfo ()
 
const std::optional< std::string > & getSwiftBridge () const
 
void setSwiftBridge (std::optional< std::string > SwiftType)
 
const std::optional< std::string > & getNSErrorDomain () const
 
void setNSErrorDomain (const std::optional< std::string > &Domain)
 
void setNSErrorDomain (const std::optional< llvm::StringRef > &Domain)
 
CommonTypeInfooperator|= (const CommonTypeInfo &RHS)
 
LLVM_DUMP_METHOD void dump (llvm::raw_ostream &OS) const
 
- Public Member Functions inherited from clang::api_notes::CommonEntityInfo
 CommonEntityInfo ()
 
std::optional< boolisSwiftPrivate () const
 
void setSwiftPrivate (std::optional< bool > Private)
 
CommonEntityInfooperator|= (const CommonEntityInfo &RHS)
 
LLVM_DUMP_METHOD void dump (llvm::raw_ostream &OS) const
 

Friends

bool operator== (const ObjCContextInfo &, const ObjCContextInfo &)
 

Additional Inherited Members

- Public Attributes inherited from clang::api_notes::CommonEntityInfo
std::string UnavailableMsg
 Message to use when this entity is unavailable.
 
unsigned Unavailable: 1
 Whether this entity is marked unavailable.
 
unsigned UnavailableInSwift: 1
 Whether this entity is marked unavailable in Swift.
 
std::string SwiftName
 Swift name of this entity.
 

Detailed Description

Describes API notes data for an Objective-C class or protocol.

Definition at line 196 of file Types.h.

Constructor & Destructor Documentation

◆ ObjCContextInfo()

clang::api_notes::ObjCContextInfo::ObjCContextInfo ( )
inline

Definition at line 220 of file Types.h.

Member Function Documentation

◆ dump()

LLVM_DUMP_METHOD void clang::api_notes::ObjCContextInfo::dump ( llvm::raw_ostream &  OS)

Definition at line 35 of file APINotesTypes.cpp.

References clang::api_notes::CommonTypeInfo::dump().

◆ getDefaultNullability()

std::optional< NullabilityKind > clang::api_notes::ObjCContextInfo::getDefaultNullability ( ) const
inline

Determine the default nullability for properties and methods of this class.

Returns the default nullability, if implied, or std::nullopt if there is none.

Definition at line 230 of file Types.h.

Referenced by operator|=(), clang::api_notes::ObjCPropertyInfo::operator|=(), and clang::api_notes::ObjCMethodInfo::operator|=().

◆ getSwiftImportAsNonGeneric()

std::optional< bool > clang::api_notes::ObjCContextInfo::getSwiftImportAsNonGeneric ( ) const
inline

Definition at line 246 of file Types.h.

Referenced by operator|=(), and ProcessAPINotes().

◆ getSwiftObjCMembers()

std::optional< bool > clang::api_notes::ObjCContextInfo::getSwiftObjCMembers ( ) const
inline

Definition at line 256 of file Types.h.

Referenced by operator|=(), and ProcessAPINotes().

◆ hasDesignatedInits()

bool clang::api_notes::ObjCContextInfo::hasDesignatedInits ( ) const
inline

Definition at line 243 of file Types.h.

◆ operator|=()

ObjCContextInfo & clang::api_notes::ObjCContextInfo::operator|= ( const ObjCContextInfo RHS)
inline

◆ setDefaultNullability()

void clang::api_notes::ObjCContextInfo::setDefaultNullability ( NullabilityKind  Kind)
inline

Set the default nullability for properties and methods of this class.

Definition at line 238 of file Types.h.

Referenced by operator|=().

◆ setHasDesignatedInits()

void clang::api_notes::ObjCContextInfo::setHasDesignatedInits ( bool  Value)
inline

Definition at line 244 of file Types.h.

◆ setSwiftImportAsNonGeneric()

void clang::api_notes::ObjCContextInfo::setSwiftImportAsNonGeneric ( std::optional< bool Value)
inline

Definition at line 251 of file Types.h.

Referenced by operator|=().

◆ setSwiftObjCMembers()

void clang::api_notes::ObjCContextInfo::setSwiftObjCMembers ( std::optional< bool Value)
inline

Definition at line 260 of file Types.h.

Referenced by operator|=().

◆ stripModuleLocalInfo()

void clang::api_notes::ObjCContextInfo::stripModuleLocalInfo ( )
inline

Strip off any information within the class information structure that is module-local, such as 'audited' flags.

Definition at line 267 of file Types.h.

Friends And Related Function Documentation

◆ operator==

bool operator== ( const ObjCContextInfo LHS,
const ObjCContextInfo RHS 
)
friend

Definition at line 297 of file Types.h.


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