Open Chinese Convert  0.4.3
A project for conversion between Traditional and Simplified Chinese
 All Data Structures Files Functions Variables Groups Pages
Functions | Variables
demo.js File Reference

Example of Node.js API. More...

Go to the source code of this file.

Functions

opencc setConversionMode (OpenCC.CONVERSION_FAST)
 
console log (converted)
 
opencc convert ("汉字", function(err, converted){console.log(converted);})
 

Variables

var OpenCC = require('./opencc')
 
var opencc = new OpenCC('zhs2zht.ini')
 
var converted = opencc.convertSync("汉字")
 

Detailed Description

Example of Node.js API.

Open Chinese Convert

Copyright 2010-2013 BYVoid byvoi.nosp@m.d@by.nosp@m.void..nosp@m.com

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

 http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Definition in file demo.js.