mirror of
https://github.com/router-for-me/CLIProxyAPI.git
synced 2026-02-18 20:30:51 +08:00
rebuild branch
This commit is contained in:
14
sdk/translator/format.go
Normal file
14
sdk/translator/format.go
Normal file
@@ -0,0 +1,14 @@
|
||||
package translator
|
||||
|
||||
// Format identifies a request/response schema used inside the proxy.
|
||||
type Format string
|
||||
|
||||
// FromString converts an arbitrary identifier to a translator format.
|
||||
func FromString(v string) Format {
|
||||
return Format(v)
|
||||
}
|
||||
|
||||
// String returns the raw schema identifier.
|
||||
func (f Format) String() string {
|
||||
return string(f)
|
||||
}
|
||||
Reference in New Issue
Block a user