ラベル edit の投稿を表示しています。 すべての投稿を表示
ラベル edit の投稿を表示しています。 すべての投稿を表示

2015年5月23日土曜日

2 - ol3.5ex 120b - esri ArcGIS REST Feature Service example with editing 2

「vector-esri-edit.js(2120-ol3ex.js)」は、マップを表示するための JavaScript ファイルです。

「2120-ol3ex.js」
var serviceUrl = 'http://services.arcgis.com/rOo16HdIMeOBI4Mb/arcgis/rest/' +
 'services/PDX_Pedestrian_Districts/FeatureServer/';
var layer = '0';
var esrijsonFormat = new ol.format.EsriJSON();
/** ol.format.EsriJSON
 * Feature format for reading and writing data in the 
 * EsriJSON format.
 * EsriJSON フォーマットデータの読み込みと書き込みのための
 * フィーチャフォーマット。(ol3 API)
 */
var vectorSource = new ol.source.Vector({
/** ol.source.Vector 
 * Provides a source of features for vector layers.
 * ベクタレイヤのフィーチャのソースを提供します。(ol3 API)
 */
 loader: function(extent, resolution, projection) {
  var url = serviceUrl + layer + '/query/?f=json&' +
   'returnGeometry=true&spatialRel=esriSpatialRelIntersects&geometry=' +
   encodeURIComponent('{"xmin":' + extent[0] + ',"ymin":' +
   extent[1] + ',"xmax":' + extent[2] + ',"ymax":' + extent[3] +
   ',"spatialReference":{"wkid":102100}}') +
   '&geometryType=esriGeometryEnvelope&inSR=102100&outFields=*' +
   '&outSR=102100';
  $.ajax({url: url, dataType: 'jsonp', success: function(response) {
  /** jQuery.ajax( url [, settings ] )
   * Perform an asynchronous HTTP (Ajax) request.
   * 非同期HTTP(Ajax)要求を実行します。
   * (jQuery[http://api.jquery.com/jQuery.ajax/])
   */
   if (response.error) {
    alert(response.error.message + '\n' +
     response.error.details.join('\n'));
   } else {
   // dataProjection will be read from document
   var features = esrijsonFormat.readFeatures(response, {
    /** readFeatures(source, opt_options)
     * Read all features from a EsriJSON source.
     *  Works with both Feature and FeatureCollection 
     * sources.
     * EsriJSON ソースからすべてのフィーチャを読み取ります。
     * フィーチャとフィーチャコレクションソースの両方で動作し
     * ます。
    * (ol3 API[説明は Stable Only のチェックを外すと表示])
     */
     featureProjection: projection
    });
    if (features.length > 0) {
     vectorSource.addFeatures(features);
     /** addFeatures(features)
      * Add a batch of features to the source.
      * フィーチャのバッチをソースに追加します。(ol3 API)
      */
    }
   }
  }});
 },
 strategy: ol.loadingstrategy.tile(new ol.tilegrid.XYZ({
 /** ol.loadingstrategy.tile(tileGrid)
  * Creates a strategy function for loading features 
  * based on a tile grid.
  * タイルグリッドに基づいて、ローディングフィーチャためのス
  * トラテジ関数を作成します。
  * (ol3 API[説明は Stable Only のチェックを外すと表示])
  */
 /** ol.tilegrid.XYZ
  * Set the grid pattern for sources accessing XYZ 
  * tiled-image servers.
  * XYZタイル画像サーバにアクセスするソースのグリッドパターン
  * を設定します。(ol3 API)
  */
  tileSize: 512
 }))
});
var vector = new ol.layer.Vector({
/** ol.layer.Vector
 * Vector data that is rendered client-side.
 * クライアント側で描画されたベクタデータ。(ol3 API)
 */
 source: vectorSource
});
var draw = new ol.interaction.Draw({
 /** ol.interaction.Draw 
  * Interaction that allows drawing geometries.
  * ジオメトリの描画を認めるインターラクション。(ol3 API)
  */
 source: vectorSource,
 type: /** @type {ol.geom.GeometryType} */ ('Polygon')
 /** @type 
  * 値のタイプ(型)の説明 - 式などで表示
  * (@use JSDoc[http://usejsdoc.org/]より)
  */
});
var select = new ol.interaction.Select();
/** ol.interaction.Select 
 * Handles selection of vector data. A 
 * ol.FeatureOverlay is maintained internally to 
 * store the selected feature(s). Which features 
 * are selected is determined by the condition 
 * option, and optionally the toggle or add/remove 
 * options.
 * ベクタデータの選択を処理します。 ol.FeatureOverlay 
 * は、選択したフィーチャを格納するために内部的に維持され
 * ています。選択されているどのフィーチャでも条件オプショ
 * ン、そして部分的にトグルまたは追加/削除オプションによっ
 * て決定されます。(ol3 API)
 */
select.setActive(false);
/** setActive(active)
 * Activate or deactivate the interaction.
 * インターラクションを有効または無効にします。
 * (ol3 API[説明は Stable Only のチェックを外すと表示])
 */
var selected = select.getFeatures();
/** getFeatures()
 * Get the selected features.
 * 選択されたフィーチャを取得します。
 * Return: Features collection(ol3 API)
 */
var modify = new ol.interaction.Modify({
/** ol.interaction.Modify 
 * Interaction for modifying vector data.
 * ベクタデータを変形するためのインタラクション。
 * (ol3 API)
 */
 features: selected
});
modify.setActive(false);
var typeSelect = document.getElementById('type');
/**
 * Let user change the interaction type.
 * @param {Event} e Change event.
 */
/** 「@param」
 * The @param tag provides the name, type, and 
 * description of a function parameter.
 * The @param tag requires you to specify the name of 
 * the parameter you are documenting. You can also 
 * include the parameter's type, enclosed in curly 
 * brackets, and a description of the parameter.
 * @paramタグは、関数パラメータの名前と型、説明を提供します。
 * @paramタグを使用すると、文書化されたパラメータの名前を
 * 指定する必要があります。また、パラメータのタイプと、中括弧
 * で囲まれたおよびパラメータの説明を含めることができます。
 * (@use JSDoc [http://usejsdoc.org/tags-param.html])
 */
typeSelect.onchange = function(e) {
/** GlobalEventHandlers.onchange()
 * The onchange property sets and returns the event handler 
 * for the change event.
 * onchange プロパティは、change イベントに対してイベントハ
 * ンドラを設定、および、返します。
 * (MDN[https://developer.mozilla.org/en-US/docs/Web/
 * API/GlobalEventHandlers/onchange])
 */
 draw.setActive(typeSelect.value === 'DRAW');
 select.setActive(typeSelect.value === 'MODIFY');
 modify.setActive(typeSelect.value === 'MODIFY');
};
var dirty = {};
selected.on('add', function(evt) {
/** on
 * Listen for a certain type of event.
 * あるタイプのイベントをリッスンします。(ol3 API)
 */
 var feature = evt.element;
 feature.on('change', function(evt) {
  dirty[evt.target.getId()] = true;
  /** getId()
   * Return: id(ol3 API)
   */
 });
});
selected.on('remove', function(evt) {
 var feature = evt.element;
 var fid = feature.getId();
 if (dirty[fid] === true) {
  var payload = '[' + esrijsonFormat.writeFeature(feature, {
  /** writeFeature(feature, opt_options)
   * Encode a feature as a EsriJSON Feature string.
   * EsriJSON フィーチャ文字列としてフィーチャをエンコード
   * (符号化)します。
   * (ol3 API[説明は Stable Only のチェックを外すと表示])
   */
   featureProjection: map.getView().getProjection()
   /** getView()
    * Get the view associated with this map. A view 
    * manages properties such as center and resolution.
    * このマップと関連するビューを取得します。ビューは、
    * 中心や解像度のような属性を管理します。
    * Return: The view that controls this map.(ol3 API)
    */
   /** getProjection()
    * Get the projection associated with the position.
    * 位置をともなった投影を取得します。(ol3 API)
    */
  }) + ']';
  var url = serviceUrl + layer + '/updateFeatures';
  $.post(url, { f: 'json', features: payload }).done(function(data) {
   /** jQuery.post( url [,data] [,success] [,dataType] )
    * Load data from the server using a HTTP POST request.
    * HTTP POST リクエストを使ってサーバからデータをロードします。
    * (jQUERY[http://api.jquery.com/jquery.post/])
    */
   /** deferred.done( doneCallbacks [, doneCallbacks ] )
    * Add handlers to be called when the Deferred object is 
    * resolved.
    * Deferred オブジェクトが resolve のとき呼び出されるハンド
    * ラを追加します。
    * (jQuery[http://api.jquery.com/deferred.done/])
    */
    var result = JSON.parse(data);
    /** JSON.parse()
     * JSON.parse() メソッドは文字列を JSON として解析し、また
     * 任意で解析によって作り出された値を変換します。
     * (MDN[https://developer.mozilla.org/ja/docs/Web/
     * JavaScript/Reference/Global_Objects/JSON/parse])
     */
    if (result.updateResults && result.updateResults.length > 0) {
    if (result.updateResults[0].success !== true) {
     var error = result.updateResults[0].error;
      alert(error.description + ' (' + error.code + ')');
    } else {
     delete dirty[fid];
    }
   }
  });
 }
});
draw.on('drawend', function(evt) {
 var feature = evt.feature;
 var payload = '[' + esrijsonFormat.writeFeature(feature, {
  featureProjection: map.getView().getProjection()
 }) + ']';
 var url = serviceUrl + layer + '/addFeatures';
 $.post(url, { f: 'json', features: payload }).done(function(data) {
  var result = JSON.parse(data);
  if (result.addResults && result.addResults.length > 0) {
   if (result.addResults[0].success === true) {
    feature.setId(result.addResults[0]['objectId']);
    /** setId()
     * Set a unique id for this feature. The id may be 
     * used to retrieve a feature from a vector source 
     * with the ol.source.Vector#getFeatureById method.
     * このフィーチャの一意のIDを設定します。 id は 
     * ol.source.Vector の getFeatureById メソッドによる
     * ベクタソースからフィーチャを取り出すために使用する
     * ことができます。(ol3 API)
     */
    vectorSource.clear();
    /** clear(opt_fast)
     * Remove all features from the source.
     * ソースからすべてのフィーチャを削除します。(ol3 API)
     */
   } else {
    var error = result.addResults[0].error;
    alert(error.description + ' (' + error.code + ')');
   }
  }
 });
});
var attribution = new ol.Attribution({
/** ol.Attribution
 * An attribution for a layer source.
 * レイヤソースの属性(ol3 API)
 */
 html: 'Tiles &copy; <a href="http://services.arcgisonline.com/ArcGIS/' +
  'rest/services/World_Topo_Map/MapServer">ArcGIS</a>'
});
var raster = new ol.layer.Tile({
/** ol.layer.Tile 
 * For layer sources that provide pre-rendered, tiled 
 * images in grids that are organized by zoom levels for 
 * specific resolutions. 
 * プリレンダリング(事前描画)を提供するレイヤソースのための、
 * 特定の解像度でのズームレベルによって編成されているグリッドの
 * タイルイメージ。(ol3 API)
 */
 source: new ol.source.XYZ({
 /** ol.source.XYZ
  * Layer source for tile data with URLs in a set XYZ 
  * format.
  * セットXYZ形式のURLを持つタイルデータのレイヤソース。
  * (ol3 API)
  */
  attributions: [attribution],
  url: 'http://server.arcgisonline.com/ArcGIS/rest/services/' +
   'World_Topo_Map/MapServer/tile/{z}/{y}/{x}'
 })
});
var map = new ol.Map({
 interactions: ol.interaction.defaults().extend([draw, select, modify]),
 /** ol.interaction.defaults
  * Set of interactions included in maps by default. 
  * Specific interactions can be excluded by setting 
  * the appropriate option to false in the constructor 
  * options, but the order of the interactions is fixed. 
  * If you want to specify a different order for 
  * interactions, you will need to create your own 
  * ol.interaction.Interaction instances and insert 
  * them into a ol.Collection in the order you want 
  * before creating your ol.Map instance.
  * デフォルトでマップに含まれるインターラクションのセット。
  * 具体的なインターラクションは、コンストラクタのオプションで
  * 適切なオプションをfalseに設定することで除外することができます
  * が、インターラクションの順番は固定されています。インターラク
  * ションに対して別の順番を指定したい場合は、独自の
  * ol.interaction.Interaction インスタンスを作成し、
  * ol.Map インスタンスを作成する前に、望む順番で 
  * ol.Collection にそれらを挿入する必要があります。(ol3 API)
  * new ol.interaction.DragRotateAndZoom()
  *(訳注:インターラクションの順番は、API を参照してください。)
  */
 layers: [raster, vector],
 target: document.getElementById('map'),
 view: new ol.View({
  center: ol.proj.transform([-122.619, 45.512], 'EPSG:4326', 'EPSG:3857'),
  /** ol.proj.transform(coordinate, source, destination)
   * Transforms a coordinate from source projection to 
   * destination projection. This returns a new coordinate 
   * (and does not modify the original).
   * ソース投影から変換先投影に座標変換します。これは、新しい座標
   * を返します(オリジナルを変更しません)。(ol3 API)
   */
  zoom: 12
 })
});

2 - ol3.5ex 120a - esri ArcGIS REST Feature Service example with editing 1

「esri ArcGIS REST Feature Service example with editing (vector-esri-edit.html)」を参考に地図を表示してみます。
説明に次のようにあります。

This example loads features from ArcGIS REST Feature Service and allows to add new features or update existing features.
この例は、ArcGIS REST フィーチャサービス空フィーチャをロードし、新しいフィーチャを追加およびすでにあるフィーチャを更新することを許可します。


HTML ファイルの作成
a Eclipse のメニューの「ファイル」->「ファイルを開く」をクリックします。





b 「ファイルを開く」ウィンドウで、「user」->「mapsite」->「ol3proj」->「v3.5.0」->「examples」->「vector-esri-edit.html」をクリックして選択し、「OK」ボタンをクリックします。
同じように「vector-esri-edit.js」を開きます。





c メニューの「ファイル」->「新規」 -> 「ファイル」をクリックします。



d 「ファイル」ウィンドウで「ol3proj」をクリックして選択し、「ファイル名」を「2120-ol3ex.html」と入力し、「次へ」ボタンをクリックします。








e 「File Template」ウィンドウで「HTML 5 Template」をクリックして選択し、「OK」ボタンをクリックします。











f 「vector-esri-edit.html」の内容をコピーして「2120-ol3ex.html」に貼り付け、修正します。
g 同じように、新規に「2120-ol3ex.js」ファイルを作成し、「File Template」ウィンドウで「JavaScript Template」をクリックして選択し、「完了」ボタンをクリックして、「vector-esri-edit.js」の内容をコピーして貼り付け、修正します。「vector-esri-edit-require.js」も「2120-ol3ex-require.js」に貼り付けます。

「2120-ol3ex.html」
<!doctype html>
<html lang="en">
 <head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="chrome=1">
  <meta name="viewport" content="initial-scale=1.0, user-scalable=no, width=device-width">
  <link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/twitter-bootstrap/2.3.1/css/bootstrap-combined.min.css" type="text/css">
  <!--
  <link rel="stylesheet" href="../css/ol.css" type="text/css">
  <link rel="stylesheet" href="./resources/layout.css" type="text/css">

  <link rel="stylesheet" href="./resources/prism/prism.css" type="text/css">
  <script src="./resources/zeroclipboard/ZeroClipboard.min.js"></script>
  「resources」の位置が変わりました。
  -->
  <!-- ディレクトリ修正 -->
  <link rel="stylesheet" href="v3.5.0/css/ol.css" type="text/css">
  <link rel="stylesheet" href="v3.5.0/examples/resources/layout.css" type="text/css">

  <link rel="stylesheet" href="v3.5.0/examples/resources/prism/prism.css" type="text/css">
  <script src="v3.5.0/examples/resources/zeroclipboard/ZeroClipboard.min.js"></script>
  <title>esri ArcGIS REST Feature Service example
   with editing</title>
 </head>
 <body>
  <!-- 
  bootstrap-combined.min.css, ol.css, layout.css
  CSSファイルで設定されたセレクタを使用。
  -->
  <div class="navbar navbar-inverse navbar-fixed-top">
   <div class="navbar-inner">
    <div class="container">
     <!--
     <a class="brand" href="./"><img src="./resources/logo-70x70.png"> OpenLayers 3 Examples</a>
     -->
     <!-- ディレクトリ修正 -->
     <a class="brand" href="v3.5.0/examples/"><img src="v3.5.0/examples/resources/logo-70x70.png"> OpenLayers 3 Examples</a>
    </div>
   </div>
  </div>
  <div class="container-fluid">
   <div class="row-fluid">
    <div class="span12">
     <div id="map" class="map"></div>
     <form class="form-inline">
      <label>Draw or modify &nbsp;</label>
      <select id="type">
       <option value="DRAW">Draw</option>
       <option value="MODIFY">Modify</option>
      </select>
     </form>
    </div>
   </div>
   <div class="row-fluid">
    <div class="span12">
     <h4 id="title">esri ArcGIS REST Feature Service example
      with editing</h4>
     <p id="shortdesc">Example of using an ArcGIS REST 
      Feature Service in an editing application.</p>
     <div id="docs">
      <p>This example loads new features from ArcGIS 
       REST Feature Service and allows to add new features 
       or update existing features.
       </p>
     </div>
     <div id="tags">vector, esri, ArcGIS, REST, Feature, 
     Service, bbox, loading, server, edit, updateFeature, 
     addFeature</div>
     <div id="api-links">Related API documentation: 
      <ul class="inline">
       <li>
        <!--<a href="../apidoc/ol.Attribution.html" title="API documentation for ol.Attribution">ol.Attribution>/a> -->
        <a href="v3.5.0/apidoc/ol.Attribution.html" title="API documentation for ol.Attribution">ol.Attribution</a>
       </li>,
       <li>
        <!--<a href="../apidoc/ol.Map.html" title="API documentation for ol.Map">ol.Map>/a> -->
        <a href="v3.5.0/apidoc/ol.Map.html" title="API documentation for ol.Map">ol.Map</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.View.html" title="API documentation for ol.View">ol.View>/a> -->
        <a href="v3.5.0/apidoc/ol.View.html" title="API documentation for ol.View">ol.View</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.format.EsriJSON.html" title="API documentation for ol.format.EsriJSON">ol.format.EsriJSON>/a> -->
        <a href="v3.5.0/apidoc/ol.format.EsriJSON.html" title="API documentation for ol.format.EsriJSON">ol.format.EsriJSON</a>
       </li>,
        <!-- <a href="../apidoc/ol.interaction.html" title="API documentation for ol.interaction">ol.interaction>/a> -->
        <a href="v3.5.0/apidoc/ol.interaction.html" title="API documentation for ol.interaction">ol.interaction</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.interaction.Draw.html" title="API documentation for ol.interaction.Draw">ol.interaction.Draw>/a> -->
        <a href="v3.5.0/apidoc/ol.interaction.Draw.html" title="API documentation for ol.interaction.Draw">ol.interaction.Draw</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.interaction.Modify.html" title="API documentation for ol.interaction.Modify">ol.interaction.Modify>/a> -->
        <a href="v3.5.0/apidoc/ol.interaction.Modify.html" title="API documentation for ol.interaction.Modify">ol.interaction.Modify</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.interaction.Select.html" title="API documentation for ol.interaction.Select">ol.interaction.Select>/a> -->
        <a href="v3.5.0/apidoc/ol.interaction.Select.html" title="API documentation for ol.interaction.Select">ol.interaction.Select</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.layer.Tile.html" title="API documentation for ol.layer.Tile">ol.layer.Tile>/a> -->
        <a href="v3.5.0/apidoc/ol.layer.Tile.html" title="API documentation for ol.layer.Tile">ol.layer.Tile</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.layer.Vector.html" title="API documentation for ol.layer.Vector">ol.layer.Vector>/a> -->
        <a href="v3.5.0/apidoc/ol.layer.Vector.html" title="API documentation for ol.layer.Vector">ol.layer.Vector</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.loadingstrategy.html" title="API documentation for ol.loadingstrategy">ol.loadingstrategy</a> -->
        <a href="v3.5.0/apidoc/ol.loadingstrategy.html" title="API documentation for ol.loadingstrategy">ol.loadingstrategy</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.proj.html" title="API documentation for ol.proj">ol.proj</a> -->
        <a href="v3.5.0/apidoc/ol.proj.html" title="API documentation for ol.proj">ol.proj</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.source.Vector.html" title="API documentation for ol.source.Vector">ol.source.Vector</a> -->
        <a href="v3.5.0/apidoc/ol.source.Vector.html" title="API documentation for ol.source.Vector">ol.source.Vector</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.source.XYZ.html" title="API documentation for ol.source.XYZ">ol.source.XYZ</a> -->
        <a href="v3.5.0/apidoc/ol.source.XYZ.html" title="API documentation for ol.source.XYZ">ol.source.XYZ</a>
       </li>,
       <li>
        <!-- <a href="../apidoc/ol.tilegrid.XYZ.html" title="API documentation for ol.tilegrid.XYZ">ol.tilegrid.XYZ</a> -->
        <a href="v3.5.0/apidoc/ol.tilegrid.XYZ.html" title="API documentation for ol.tilegrid.XYZ">ol.tilegrid.XYZ</a>
       </li>
      </ui>
     </div>
   </div>
  </div>
  <div class="row-fluid">
   <hr>
   <form method="POST" target="_blank" action="http://jsfiddle.net/api/post/jquery/1.11.0/">
    <input type="button" class="btn btn-info" id="copy-button" value="Copy example code">
    <input type="submit" class="btn btn-primary" id="jsfiddle-button" value="Create JSFiddle">
    <textarea class="hidden" name="js">
// --- 省略 ---
&lt;/html&gt;</code></pre>
    </div>
   </div>
  </div>
  <script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
  <script src="http://maxcdn.bootstrapcdn.com/twitter-bootstrap/2.3.1/js/bootstrap.min.js"></script>
  <!--
  <script src="./resources/common.js"></script>
  <script src="./resources/prism/prism.min.js"></script>
  -->
  <!-- ディレクトリ修正
   CommonJS と
   prism.js
 -->
  <script src="v3.5.0/examples/resources/common.js"></script>
  <script src="v3.5.0/examples/resources/prism/prism.min.js"></script>
  <!-- 
  <script src="loader.js?id=vector-esri-edit"></script>
  -->
  <!-- ファイル修正 -->  <!-- ディレクトリ修正 -->
  <script src="loader.js?id=2120-ol3ex"></script>
  </body>
</html>


COMMONJS は

COMMONJS
http://webpack.github.io/docs/commonjs.html

に、次のようにあります。

The CommonJS group defined a module format to solve JavaScript scope issues by making sure each module is executed in its own namespace.
This is achieved by forcing modules to explicitly export those variables it wants to expose to the “universe”, and also by defining those other modules required to properly work.
To achieve this CommonJS give you two tools:
the require() function, which allows to import a given module into the current scope.
the module object, which allows to export something from the current scope.

CommonJSグループは、それ自身の名前空間内で実行されている各モジュールを確認することによって、JavaScriptのスコープ問題を解決するためのモジュールフォーマットを定義しました。
これは、それが「universe(?)」に公開したい変数を明示的にエクスポートするモジュールを強制することによって、同じように、正常に動作するのに必要な他のモジュールを定義することによって、達成されます。
この CommonJS を達成するために2つのツールを与えます:
require()関数、指定したモジュールを現在のスコープにインポートすることができます。
モジュールオブジェクト、現在のスコープからエクスポートすることができます。


Prism は、

Prism
http://prismjs.com/

に、次のようにあります。

Prism is a lightweight, extensible syntax highlighter, built with modern web standards in mind. It’s a spin-off from Dabblet and is tested there daily by thousands.
Prismは、最新のWeb標準に構築されたことを考慮し軽量で拡張可能なシンタックスハイライトです。それは Dabblet からスピンオフで、何千人も日々そこで試験されています。


ZeroClipboard は

ZeroClipboard v2.x
http://zeroclipboard.org/

に、次のようにあります。

The ZeroClipboard library provides an easy way to copy text to the clipboard using an invisible Adobe Flash movie and a JavaScript interface.
ZeroClipboard ライブラリは、見えない Adobe Flash ムービーとJavaScript のインターフェイスを使用してテキストをクリップボードにコピーする簡単な方法を提供します。

Debian 8 では動作しませんでした。ボタンを右クリックしたときに flash のコンテキストメニューが表示されると動作しています。