LLDB mainline
Public Member Functions | List of all members
lldb_private::StandardTildeExpressionResolver Class Reference

#include <TildeExpressionResolver.h>

Inheritance diagram for lldb_private::StandardTildeExpressionResolver:
Inheritance graph
[legend]

Public Member Functions

bool ResolveExact (llvm::StringRef Expr, llvm::SmallVectorImpl< char > &Output) override
 Resolve a Tilde Expression contained according to bash rules.
 
bool ResolvePartial (llvm::StringRef Expr, llvm::StringSet<> &Output) override
 Auto-complete a tilde expression with all matching values.
 
- Public Member Functions inherited from lldb_private::TildeExpressionResolver
virtual ~TildeExpressionResolver ()
 
virtual bool ResolveExact (llvm::StringRef Expr, llvm::SmallVectorImpl< char > &Output)=0
 Resolve a Tilde Expression contained according to bash rules.
 
virtual bool ResolvePartial (llvm::StringRef Expr, llvm::StringSet<> &Output)=0
 Auto-complete a tilde expression with all matching values.
 
bool ResolveFullPath (llvm::StringRef Expr, llvm::SmallVectorImpl< char > &Output)
 Resolve an entire path that begins with a tilde expression, replacing the username portion with the matched result.
 

Detailed Description

Definition at line 56 of file TildeExpressionResolver.h.

Member Function Documentation

◆ ResolveExact()

bool StandardTildeExpressionResolver::ResolveExact ( llvm::StringRef  Expr,
llvm::SmallVectorImpl< char > &  Output 
)
overridevirtual

Resolve a Tilde Expression contained according to bash rules.

Parameters
ExprContains the tilde expression to resolve. A valid tilde expression must begin with a tilde and contain only non separator characters.
OutputContains the resolved tilde expression, or the original input if the tilde expression could not be resolved.
Returns
true if Expr was successfully resolved, false otherwise.

Implements lldb_private::TildeExpressionResolver.

Definition at line 32 of file TildeExpressionResolver.cpp.

◆ ResolvePartial()

bool StandardTildeExpressionResolver::ResolvePartial ( llvm::StringRef  Expr,
llvm::StringSet<> &  Output 
)
overridevirtual

Auto-complete a tilde expression with all matching values.

Parameters
ExprContains the tilde expression prefix to resolve. See ResolveExact() for validity rules.
OutputContains all matching home directories, each one itself unresolved (i.e. you need to call ResolveExact on each item to turn it into a real path).
Returns
true if there were any matches, false otherwise.

Implements lldb_private::TildeExpressionResolver.

Definition at line 42 of file TildeExpressionResolver.cpp.


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