You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by je...@apache.org on 2014/11/09 02:00:40 UTC

svn commit: r1637617 - in /thrift/cms-site/trunk/content: lib/haxe.md tutorial/haxe.md

Author: jensg
Date: Sun Nov  9 01:00:40 2014
New Revision: 1637617

URL: http://svn.apache.org/r1637617
Log:
added Haxe lib/tutorial pages

Added:
    thrift/cms-site/trunk/content/lib/haxe.md
    thrift/cms-site/trunk/content/tutorial/haxe.md

Added: thrift/cms-site/trunk/content/lib/haxe.md
URL: http://svn.apache.org/viewvc/thrift/cms-site/trunk/content/lib/haxe.md?rev=1637617&view=auto
==============================================================================
--- thrift/cms-site/trunk/content/lib/haxe.md (added)
+++ thrift/cms-site/trunk/content/lib/haxe.md Sun Nov  9 01:00:40 2014
@@ -0,0 +1,19 @@
+Title:     Haxe library
+Notice:    Licensed to the Apache Software Foundation (ASF) under one
+           or more contributor license agreements.  See the NOTICE file
+           distributed with this work for additional information
+           regarding copyright ownership.  The ASF licenses this file
+           to you 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.
+
+[snippet:path=lib/haxe/README.md:lines=22]
\ No newline at end of file

Added: thrift/cms-site/trunk/content/tutorial/haxe.md
URL: http://svn.apache.org/viewvc/thrift/cms-site/trunk/content/tutorial/haxe.md?rev=1637617&view=auto
==============================================================================
--- thrift/cms-site/trunk/content/tutorial/haxe.md (added)
+++ thrift/cms-site/trunk/content/tutorial/haxe.md Sun Nov  9 01:00:40 2014
@@ -0,0 +1,29 @@
+---
+title: "Haxe Framework"
+library_lang: "haxe"
+---
+{% include 'tutorial_intro.md' %}
+
+### Prerequisites
+* Thrift requires at least Haxe 3.1.3. (You may try with older versions on your own luck).
+
+### Client 
+For this tutorial, we put both the server and the client main code into one single program. 
+Depending on the arguments passed, it runs as a server or as a client program.
+
+  [snippet:path=tutorial/haxe/src/Main.hx:lang=java:lines=20,332]
+
+Were done with the client, but need some more for the server: A service handler implementaion.
+  
+### Server
+As the name suggests, the service handler implements the Thrift service on the server side. 
+The code to achieve this is as follows:
+
+  [snippet:path=tutorial/haxe/src/CalculatorHandler.hx:lang=java:lines=20,102]
+
+### Additional Information
+
+Similar to Thrift, Haxe supports different compiler targets. Depending on the target, some features 
+may or may not be supported. For example, if you plan to use Flash or JavaScript targets, there is 
+currently no way to pass command line arguments to the program.
+