Skip to content

hongxdong/go-opencc

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

go-opencc

opencc wrapper for Golang

Install

Run 'go get github.com/stevenyao/go-opencc'

Example

package main

import "fmt"
import "github.com/stevenyao/go-opencc"

const (
	input = "中国鼠标软件打印机"
	config_s2t = "/usr/share/opencc/s2t.json"
	config_t2s = "/usr/share/opencc/t2s.json"
)

func main() {
	fmt.Println("Test Converter class:")
	c := opencc.NewConverter(config_s2t)
	defer c.Close()
	output := c.Convert(input)
	fmt.Println(output)
}

About

opencc wrapper for Golang

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 56.8%
  • C 43.2%