com.vaadin.polymer.app.AppPouchdbSyncElement Maven / Gradle / Ivy
/*
* This code was generated with Vaadin Web Component GWT API Generator,
* from app-pouchdb project by The Polymer Authors
* that is licensed with http://polymer.github.io/LICENSE.txt license.
*/
package com.vaadin.polymer.app;
import com.vaadin.polymer.elemental.*;
import com.google.gwt.core.client.JavaScriptObject;
import com.google.gwt.core.client.JsArray;
import jsinterop.annotations.JsOverlay;
import jsinterop.annotations.JsProperty;
import jsinterop.annotations.JsType;
/**
* app-pouchdb-sync
arranges for one-directional or bi-directional
synchronization between two PouchDB databases. For one-directional
synchronization, it forwards to PouchDB.replicate
, and for bi-directional
synchronization, it forwards to PouchDB.sync
.
* Here is an example of bi-directional synchronization between a local database
and a remote one:
* <app-pouchdb-sync
* src="cats"
* target="https://example.com:5678/cats"
* bidirectional>
* </app-pouchdb-sync>
*
* For more information on PouchDB synchronization topics, please refer to the
documentation here.
*/
@JsType(isNative=true)
public interface AppPouchdbSyncElement extends HTMLElement {
@JsOverlay public static final String TAG = "app-pouchdb-sync";
@JsOverlay public static final String SRC = "app-pouchdb/app-pouchdb-sync.html";
/**
* While false
, synchronization will only happen from the src
to the
target
. One-directional synchronization follows the semantics of
PouchDB.replicate
. Set to true
to make the sync bidirectional,
which uses PouchDB.sync
instead.
*
* JavaScript Info:
* @property bidirectional
* @type Boolean
*
*/
@JsProperty boolean getBidirectional();
/**
* While false
, synchronization will only happen from the src
to the
target
. One-directional synchronization follows the semantics of
PouchDB.replicate
. Set to true
to make the sync bidirectional,
which uses PouchDB.sync
instead.
*
* JavaScript Info:
* @property bidirectional
* @type Boolean
*
*/
@JsProperty void setBidirectional(boolean value);
/**
* Set to true to log change events that are emitted by the sync
instance.
*
* JavaScript Info:
* @property log
* @type Boolean
*
*/
@JsProperty boolean getLog();
/**
* Set to true to log change events that are emitted by the sync
instance.
*
* JavaScript Info:
* @property log
* @type Boolean
*
*/
@JsProperty void setLog(boolean value);
/**
* An event emitter that notifies of events in the synchronization
process.
*
* JavaScript Info:
* @property sync
* @type Object
*
*/
@JsProperty JavaScriptObject getSync();
/**
* An event emitter that notifies of events in the synchronization
process.
*
* JavaScript Info:
* @property sync
* @type Object
*
*/
@JsProperty void setSync(JavaScriptObject value);
/**
* The source to sync from. If this sync is bidirectional
, then the
src
and target
values are interchangeable.
*
* JavaScript Info:
* @property src
* @type String
*
*/
@JsProperty String getSrc();
/**
* The source to sync from. If this sync is bidirectional
, then the
src
and target
values are interchangeable.
*
* JavaScript Info:
* @property src
* @type String
*
*/
@JsProperty void setSrc(String value);
/**
* The target
to sync to. If this sync is bidirectional
, then the
src
and target
values are interchangeable.
*
* JavaScript Info:
* @property target
* @type String
*
*/
@JsProperty String getTarget();
/**
* The target
to sync to. If this sync is bidirectional
, then the
src
and target
values are interchangeable.
*
* JavaScript Info:
* @property target
* @type String
*
*/
@JsProperty void setTarget(String value);
}