github.com/altipla-consulting/ravendb-go-client@v0.1.3/character.go (about)

     1  package ravendb
     2  
     3  // helpers to make Java porting easier
     4  
     5  func isLetterOrDigit(r rune) bool {
     6  	if r >= 'a' && r <= 'z' {
     7  		return true
     8  	}
     9  	if r >= 'A' && r <= 'Z' {
    10  		return true
    11  	}
    12  	if r >= '0' && r <= '9' {
    13  		return true
    14  	}
    15  	return false
    16  }
    17  
    18  func isLetter(r rune) bool {
    19  	if r >= 'a' && r <= 'z' {
    20  		return true
    21  	}
    22  	if r >= 'A' && r <= 'Z' {
    23  		return true
    24  	}
    25  	return false
    26  }