Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
package org.wildfly.swarm.config.infinispan.cache_container;
import org.wildfly.swarm.config.runtime.AttributeDocumentation;
import org.wildfly.swarm.config.runtime.ResourceDocumentation;
import org.wildfly.swarm.config.runtime.SingletonResource;
import org.wildfly.swarm.config.runtime.Addresses;
import org.wildfly.swarm.config.runtime.ResourceType;
import org.wildfly.swarm.config.runtime.Implicit;
import java.beans.PropertyChangeSupport;
import java.beans.PropertyChangeListener;
import org.wildfly.swarm.config.runtime.ModelNodeBinding;
import java.util.Map;
/**
* Defines a table used to store cache entries whose keys cannot be expressed as
* strings.
*/
@Addresses({
"/subsystem=infinispan/cache-container=*/invalidation-cache=*/store=binary-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/invalidation-cache=*/store=mixed-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/local-cache=*/store=binary-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/local-cache=*/store=mixed-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/replicated-cache=*/store=binary-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/replicated-cache=*/store=mixed-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/distributed-cache=*/store=binary-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/distributed-cache=*/store=mixed-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/scattered-cache=*/store=binary-jdbc/table=binary",
"/subsystem=infinispan/cache-container=*/scattered-cache=*/store=mixed-jdbc/table=binary"})
@ResourceType("table")
@Implicit
public class BinaryTable>
implements
org.wildfly.swarm.config.runtime.Keyed {
private String key;
private PropertyChangeSupport pcs;
@AttributeDocumentation("For DB inserts, the batch size determines how many inserts are batched together.")
private Integer batchSize;
@AttributeDocumentation("Indicates whether the store should create this database table when the cache starts.")
private Boolean createOnStart;
@AttributeDocumentation("A database column to hold cache entry data.")
private Map dataColumn;
@AttributeDocumentation("Indicates whether the store should drop this database table when the cache stops.")
private Boolean dropOnStop;
@AttributeDocumentation("For DB queries, the fetch size will be used to set the fetch size on ResultSets.")
private Integer fetchSize;
@AttributeDocumentation("A database column to hold cache entry ids.")
private Map idColumn;
@AttributeDocumentation("The prefix for the database table name.")
private String prefix;
@AttributeDocumentation("A database column to hold cache entry timestamps.")
private Map timestampColumn;
public BinaryTable() {
super();
this.key = "binary";
this.pcs = new PropertyChangeSupport(this);
}
public String getKey() {
return this.key;
}
/**
* Adds a property change listener
*/
public void addPropertyChangeListener(PropertyChangeListener listener) {
if (null == this.pcs)
this.pcs = new PropertyChangeSupport(this);
this.pcs.addPropertyChangeListener(listener);
}
/**
* Removes a property change listener
*/
public void removePropertyChangeListener(
java.beans.PropertyChangeListener listener) {
if (this.pcs != null)
this.pcs.removePropertyChangeListener(listener);
}
/**
* For DB inserts, the batch size determines how many inserts are batched
* together.
*
* @deprecated Deprecated. Use max-batch-size instead.
*/
@Deprecated
@ModelNodeBinding(detypedName = "batch-size")
public Integer batchSize() {
return this.batchSize;
}
/**
* For DB inserts, the batch size determines how many inserts are batched
* together.
*
* @deprecated Deprecated. Use max-batch-size instead.
*/
@SuppressWarnings("unchecked")
@Deprecated
public T batchSize(java.lang.Integer value) {
Object oldValue = this.batchSize;
this.batchSize = value;
if (this.pcs != null)
this.pcs.firePropertyChange("batchSize", oldValue, value);
return (T) this;
}
/**
* Indicates whether the store should create this database table when the
* cache starts.
*/
@ModelNodeBinding(detypedName = "create-on-start")
public Boolean createOnStart() {
return this.createOnStart;
}
/**
* Indicates whether the store should create this database table when the
* cache starts.
*/
@SuppressWarnings("unchecked")
public T createOnStart(java.lang.Boolean value) {
Object oldValue = this.createOnStart;
this.createOnStart = value;
if (this.pcs != null)
this.pcs.firePropertyChange("createOnStart", oldValue, value);
return (T) this;
}
/**
* A database column to hold cache entry data.
*/
@ModelNodeBinding(detypedName = "data-column")
public Map dataColumn() {
return this.dataColumn;
}
/**
* A database column to hold cache entry data.
*/
@SuppressWarnings("unchecked")
public T dataColumn(java.util.Map value) {
Object oldValue = this.dataColumn;
this.dataColumn = value;
if (this.pcs != null)
this.pcs.firePropertyChange("dataColumn", oldValue, value);
return (T) this;
}
/**
* A database column to hold cache entry data.
*/
@SuppressWarnings("unchecked")
public T dataColumn(java.lang.String key, java.lang.Object value) {
if (this.dataColumn == null) {
this.dataColumn = new java.util.HashMap<>();
}
this.dataColumn.put(key, value);
return (T) this;
}
/**
* Indicates whether the store should drop this database table when the
* cache stops.
*/
@ModelNodeBinding(detypedName = "drop-on-stop")
public Boolean dropOnStop() {
return this.dropOnStop;
}
/**
* Indicates whether the store should drop this database table when the
* cache stops.
*/
@SuppressWarnings("unchecked")
public T dropOnStop(java.lang.Boolean value) {
Object oldValue = this.dropOnStop;
this.dropOnStop = value;
if (this.pcs != null)
this.pcs.firePropertyChange("dropOnStop", oldValue, value);
return (T) this;
}
/**
* For DB queries, the fetch size will be used to set the fetch size on
* ResultSets.
*/
@ModelNodeBinding(detypedName = "fetch-size")
public Integer fetchSize() {
return this.fetchSize;
}
/**
* For DB queries, the fetch size will be used to set the fetch size on
* ResultSets.
*/
@SuppressWarnings("unchecked")
public T fetchSize(java.lang.Integer value) {
Object oldValue = this.fetchSize;
this.fetchSize = value;
if (this.pcs != null)
this.pcs.firePropertyChange("fetchSize", oldValue, value);
return (T) this;
}
/**
* A database column to hold cache entry ids.
*/
@ModelNodeBinding(detypedName = "id-column")
public Map idColumn() {
return this.idColumn;
}
/**
* A database column to hold cache entry ids.
*/
@SuppressWarnings("unchecked")
public T idColumn(java.util.Map value) {
Object oldValue = this.idColumn;
this.idColumn = value;
if (this.pcs != null)
this.pcs.firePropertyChange("idColumn", oldValue, value);
return (T) this;
}
/**
* A database column to hold cache entry ids.
*/
@SuppressWarnings("unchecked")
public T idColumn(java.lang.String key, java.lang.Object value) {
if (this.idColumn == null) {
this.idColumn = new java.util.HashMap<>();
}
this.idColumn.put(key, value);
return (T) this;
}
/**
* The prefix for the database table name.
*/
@ModelNodeBinding(detypedName = "prefix")
public String prefix() {
return this.prefix;
}
/**
* The prefix for the database table name.
*/
@SuppressWarnings("unchecked")
public T prefix(java.lang.String value) {
Object oldValue = this.prefix;
this.prefix = value;
if (this.pcs != null)
this.pcs.firePropertyChange("prefix", oldValue, value);
return (T) this;
}
/**
* A database column to hold cache entry timestamps.
*/
@ModelNodeBinding(detypedName = "timestamp-column")
public Map timestampColumn() {
return this.timestampColumn;
}
/**
* A database column to hold cache entry timestamps.
*/
@SuppressWarnings("unchecked")
public T timestampColumn(java.util.Map value) {
Object oldValue = this.timestampColumn;
this.timestampColumn = value;
if (this.pcs != null)
this.pcs.firePropertyChange("timestampColumn", oldValue, value);
return (T) this;
}
/**
* A database column to hold cache entry timestamps.
*/
@SuppressWarnings("unchecked")
public T timestampColumn(java.lang.String key, java.lang.Object value) {
if (this.timestampColumn == null) {
this.timestampColumn = new java.util.HashMap<>();
}
this.timestampColumn.put(key, value);
return (T) this;
}
}