clang 19.0.0git
Public Types | Public Member Functions | List of all members
clang::tooling::RequiredRefactoringOption< T, typename > Class Template Reference

A required refactoring option that stores a value of type T. More...

#include "clang/Tooling/Refactoring/RefactoringOptions.h"

Inheritance diagram for clang::tooling::RequiredRefactoringOption< T, typename >:
Inheritance graph
[legend]

Public Types

using ValueType = T
 
- Public Types inherited from clang::tooling::OptionalRefactoringOption< T, typename >
using ValueType = std::optional< T >
 

Public Member Functions

const ValueTypegetValue () const
 
bool isRequired () const final
 True when this option must be specified before invoking the refactoring action.
 
- Public Member Functions inherited from clang::tooling::OptionalRefactoringOption< T, typename >
void passToVisitor (RefactoringOptionVisitor &Visitor) final
 Invokes the visit method in the option consumer that's appropriate for the option's value type.
 
bool isRequired () const override
 True when this option must be specified before invoking the refactoring action.
 
const ValueTypegetValue () const
 
- Public Member Functions inherited from clang::tooling::RefactoringOption
virtual ~RefactoringOption ()
 
virtual StringRef getName () const =0
 Returns the name of the refactoring option.
 
virtual StringRef getDescription () const =0
 
virtual bool isRequired () const =0
 True when this option must be specified before invoking the refactoring action.
 
virtual void passToVisitor (RefactoringOptionVisitor &Visitor)=0
 Invokes the visit method in the option consumer that's appropriate for the option's value type.
 

Additional Inherited Members

- Protected Attributes inherited from clang::tooling::OptionalRefactoringOption< T, typename >
std::optional< T > Value
 

Detailed Description

template<typename T, typename = std::enable_if_t<traits::IsValidOptionType<T>::value>>
class clang::tooling::RequiredRefactoringOption< T, typename >

A required refactoring option that stores a value of type T.

Definition at line 45 of file RefactoringOptions.h.

Member Typedef Documentation

◆ ValueType

template<typename T , typename = std::enable_if_t<traits::IsValidOptionType<T>::value>>
using clang::tooling::RequiredRefactoringOption< T, typename >::ValueType = T

Definition at line 47 of file RefactoringOptions.h.

Member Function Documentation

◆ getValue()

template<typename T , typename = std::enable_if_t<traits::IsValidOptionType<T>::value>>
const ValueType & clang::tooling::RequiredRefactoringOption< T, typename >::getValue ( ) const
inline

Definition at line 49 of file RefactoringOptions.h.

◆ isRequired()

template<typename T , typename = std::enable_if_t<traits::IsValidOptionType<T>::value>>
bool clang::tooling::RequiredRefactoringOption< T, typename >::isRequired ( ) const
inlinefinalvirtual

True when this option must be specified before invoking the refactoring action.

Reimplemented from clang::tooling::OptionalRefactoringOption< T, typename >.

Definition at line 52 of file RefactoringOptions.h.


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