Exemple #1
0
 /**
  * Returns the datapoints for a given item and group address. This method iterates over all
  * registered KNX binding providers to find the result.
  *
  * @param itemName the item name for the datapoint
  * @param groupAddress the group address associated to the datapoint
  * @return the datapoints which corresponds to the given item and group address
  */
 private Iterable<Datapoint> getDatapoints(String itemName, GroupAddress groupAddress) {
   for (KNXBindingProvider provider : providers) {
     Iterable<Datapoint> datapoints = provider.getDatapoints(itemName, groupAddress);
     if (datapoints != null) return datapoints;
   }
   return null;
 }
Exemple #2
0
 /**
  * Returns the datapoints for a given item and type class. This method iterates over all
  * registered KNX binding providers to find the result.
  *
  * @param itemName the item name for the datapoints
  * @param typeClass the type class associated to the datapoints
  * @return the datapoints which corresponds to the given item and type class
  */
 private Iterable<Datapoint> getDatapoints(
     final String itemName, final Class<? extends Type> typeClass) {
   Set<Datapoint> datapoints = new HashSet<Datapoint>();
   for (KNXBindingProvider provider : providers) {
     for (Datapoint datapoint : provider.getDatapoints(itemName, typeClass)) {
       datapoints.add(datapoint);
     }
   }
   return datapoints;
 }