C# 클래스 NGit.Util.QuotedString

Utility functions related to quoted string handling.
Utility functions related to quoted string handling.
파일 보기 프로젝트 열기: red-gate/ngit

공개 프로퍼티들

프로퍼티 타입 설명
BOURNE QuotedString.BourneStyle
BOURNE_USER_PATH QuotedString.BourneUserPathStyle
GIT_PATH QuotedString.GitPathStyle

공개 메소드들

메소드 설명
Dequote ( byte @in, int offset, int end ) : string

Decode a previously quoted input, scanning a UTF-8 encoded buffer.

Decode a previously quoted input, scanning a UTF-8 encoded buffer.

This method must match quote such that:

 a.equals(dequote(Constants.encode(quote(a)))); 
is true for any a.

This method removes any opening/closing quotation marks added by Quote(string) .

Dequote ( string @in ) : string

Clean a previously quoted input, decoding the result via UTF-8.

Clean a previously quoted input, decoding the result via UTF-8.

This method must match quote such that:

 a.equals(dequote(quote(a))); 
is true for any a.
Quote ( string @in ) : string

Quote an input string by the quoting rules.

Quote an input string by the quoting rules.

If the input string does not require any quoting, the same String reference is returned to the caller.

Otherwise a quoted string is returned, including the opening and closing quotation marks at the start and end of the string. If the style does not permit raw Unicode characters then the string will first be encoded in UTF-8, with unprintable sequences possibly escaped by the rules.

메소드 상세

Dequote() 공개 추상적인 메소드

Decode a previously quoted input, scanning a UTF-8 encoded buffer.
Decode a previously quoted input, scanning a UTF-8 encoded buffer.

This method must match quote such that:

 a.equals(dequote(Constants.encode(quote(a)))); 
is true for any a.

This method removes any opening/closing quotation marks added by Quote(string) .

public abstract Dequote ( byte @in, int offset, int end ) : string
@in byte
offset int first position within in to scan.
end int one position past in in to scan.
리턴 string

Dequote() 공개 메소드

Clean a previously quoted input, decoding the result via UTF-8.
Clean a previously quoted input, decoding the result via UTF-8.

This method must match quote such that:

 a.equals(dequote(quote(a))); 
is true for any a.
public Dequote ( string @in ) : string
@in string
리턴 string

Quote() 공개 추상적인 메소드

Quote an input string by the quoting rules.
Quote an input string by the quoting rules.

If the input string does not require any quoting, the same String reference is returned to the caller.

Otherwise a quoted string is returned, including the opening and closing quotation marks at the start and end of the string. If the style does not permit raw Unicode characters then the string will first be encoded in UTF-8, with unprintable sequences possibly escaped by the rules.

public abstract Quote ( string @in ) : string
@in string
리턴 string

프로퍼티 상세

BOURNE 공개적으로 정적으로 프로퍼티

Quoting style used by the Bourne shell.
Quoting style used by the Bourne shell.

Quotes are unconditionally inserted during Quote(string) . This protects shell meta-characters like $ or ~ from being recognized as special.

public static QuotedString.BourneStyle,NGit.Util BOURNE
리턴 QuotedString.BourneStyle

BOURNE_USER_PATH 공개적으로 정적으로 프로퍼티

Bourne style, but permits ~user at the start of the string.
Bourne style, but permits ~user at the start of the string.
public static QuotedString.BourneUserPathStyle,NGit.Util BOURNE_USER_PATH
리턴 QuotedString.BourneUserPathStyle

GIT_PATH 공개적으로 정적으로 프로퍼티

Quoting style that obeys the rules Git applies to file names
public static QuotedString.GitPathStyle,NGit.Util GIT_PATH
리턴 QuotedString.GitPathStyle