On this page:
- gulp-ice-builder - Gulp plug-in to integrate
slice2jswith the gulp build system
The following bower package is provided for developers of browser-based applications:
$ npm install ice --save
You can also run
npm install ice@latest --save to get the latest patches and bug fixes.
To install with
$ bower install ice --save
You can also run
ice#master --save to get the latest patches and bug fixes.
slice2js) can be installed with this command:
$ npm install slice2js --save-dev
This command builds the compiler from source therefore you must have a supported C++ compiler installed.
In order to use
slice2js on the command line, use the
npm --global option to install this package.
slice2js package includes all of the standard Slice files and automatically adds the slice directory to the include file search path.
You can use several top-level Ice package in your Node.js applications, as shown below:
var Ice = require('ice').Ice; var Glacier2 = require('ice').Glacier2; var IceStorm = require('ice').IceStorm; var IceGrid = require('ice').IceGrid; var communicator = Ice.initialize(process.argv); var proxy = communicator.stringToProxy("hello:tcp -h localhost -p 10000");
Add the necessary
Minified versions are available with the
<script src="https://cdnjs.cloudflare.com/ajax/libs/ice/3.6.0/Ice.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/ice/3.6.0/Glacier2.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/ice/3.6.0/IceStorm.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/ice/3.6.0/IceGrid.min.js"></script>
A CDN is a great option for applications which do not wish to host all of their website's files themselves. Among other things using a cdn will help to reduce bandwidth and allow caching across multiple websites.
var slice2js = require('slice2js'); slice2js.compile(["Hello.ice"]);
If you installed the
slice2js packge globally, you can also run
slice2js on the command line.
Refer to the manual for a description of the arguments accepted by
Using the sample programs
The Ice sample programs are provided in a GitHub repository. You can browse this repository to see build and usage instructions for all supported programming languages. Simply clone this repository and use its 3.6 branch:
git clone -b 3.6 https://github.com/zeroc-ice/ice-demos.git cd ice-demos