convert to prefix byte
This commit is contained in:
parent
7b87e08e89
commit
50bd7d04ef
2 changed files with 9 additions and 9 deletions
|
|
@ -60,20 +60,20 @@ const (
|
|||
Provenance
|
||||
)
|
||||
|
||||
func (d Direction) Prefix() string {
|
||||
func (d Direction) Prefix() byte {
|
||||
switch d {
|
||||
case Any:
|
||||
return "a"
|
||||
return 'a'
|
||||
case Subject:
|
||||
return "s"
|
||||
return 's'
|
||||
case Predicate:
|
||||
return "p"
|
||||
return 'p'
|
||||
case Provenance:
|
||||
return "c"
|
||||
return 'c'
|
||||
case Object:
|
||||
return "o"
|
||||
return 'o'
|
||||
default:
|
||||
return fmt.Sprint("illegal direction:", byte(d))
|
||||
return '\x00'
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue