コード例 #1
0
ファイル: UnionViewFactory.java プロジェクト: arberzal/esper
  public void setProvideCapability(
      ViewCapability viewCapability, ViewResourceCallback resourceCallback) {
    if (!canProvideCapability(viewCapability)) {
      throw new UnsupportedOperationException(
          "View capability " + viewCapability.getClass().getSimpleName() + " not supported");
    }

    if (viewCapability instanceof RemoveStreamViewCapability) {
      for (ViewFactory viewFactory : viewFactories) {
        viewFactory.setProvideCapability(viewCapability, resourceCallback);
      }
    }
  }
コード例 #2
0
 public void setProvideCapability(
     ViewCapability viewCapability, ViewResourceCallback resourceCallback) {
   if (!canProvideCapability(viewCapability)) {
     throw new UnsupportedOperationException(
         "View capability " + viewCapability.getClass().getSimpleName() + " not supported");
   }
   if (viewCapability instanceof RemoveStreamViewCapability) {
     isRemoveStreamHandling = true;
     return;
   }
   if (relativeAccessGetterImpl == null) {
     relativeAccessGetterImpl = new RelativeAccessByEventNIndexMap();
   }
   resourceCallback.setViewResource(relativeAccessGetterImpl);
 }