javax.naming.Binding.<init>()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(5.4k)|赞(0)|评价(0)|浏览(146)

本文整理了Java中javax.naming.Binding.<init>()方法的一些代码示例,展示了Binding.<init>()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Binding.<init>()方法的具体详情如下:
包路径:javax.naming.Binding
类名称:Binding
方法名:<init>

Binding.<init>介绍

暂无

代码示例

代码示例来源:origin: spring-projects/spring-framework

@Override
  protected Binding createObject(String strippedName, Object obj) {
    return new Binding(strippedName, obj);
  }
}

代码示例来源:origin: spring-projects/spring-framework

@Override
  protected Binding createObject(String strippedName, Object obj) {
    return new Binding(strippedName, obj);
  }
}

代码示例来源:origin: wildfly/wildfly

private ContextNode(final ContextNode parentNode, final String name, final Name fullName, final NamingContext context) {
  super(fullName, new Binding(getLastComponent(fullName), Context.class.getName(), context));
  this.name = name;
  this.parentNode = parentNode;
}

代码示例来源:origin: wildfly/wildfly

@Override
 public Object nextElement() {
   Map.Entry<String, Object> entry = getNext();
   return new Binding(entry.getKey(), entry.getValue());
 }
}

代码示例来源:origin: apache/activemq

public Object nextElement() {
    Map.Entry entry = getNext();
    return new Binding((String)entry.getKey(), entry.getValue());
  }
}

代码示例来源:origin: stackoverflow.com

Binding binding = new Binding();
GroovyShell shell = new GroovyShell(binding);
Object value = shell.evaluate("for (x=0; x<5; x++){println "Hello"}; return x");

代码示例来源:origin: stackoverflow.com

// call groovy expressions from Java code
Binding binding = new Binding();
binding.setVariable("foo", new Integer(2));
GroovyShell shell = new GroovyShell(binding);

Object value = shell.evaluate(groovyScript);

代码示例来源:origin: wildfly/wildfly

protected Void foundBindContext(final ContextNode contextNode) throws NamingException {
    final String childName = getLastComponent(targetName);
    final Binding binding = new Binding(childName, className, object, true);
    final BindingNode bindingNode = new BindingNode(targetName, binding);
    contextNode.addChild(childName, bindingNode);
    fireEvent(contextNode, targetName, null, binding, NamingEvent.OBJECT_ADDED, "bind");
    return null;
  }
}

代码示例来源:origin: wildfly/wildfly

protected Void foundBindContext(final ContextNode contextNode) throws NamingException {
    final String childName = getLastComponent(targetName);
    final Binding binding = new Binding(childName, className, object, true);
    final BindingNode bindingNode = new BindingNode(targetName, binding);
    final TreeNode previous = contextNode.replaceChild(childName, bindingNode);
    final Binding previousBinding = previous != null ? previous.binding : null;
    fireEvent(contextNode, targetName, previousBinding, binding, previousBinding != null ? NamingEvent.OBJECT_CHANGED : NamingEvent.OBJECT_ADDED, "rebind");
    return null;
  }
}

代码示例来源:origin: stackoverflow.com

public class MyCell : ViewCell
{
  public MyCell() : base()
  {
    RelativeLayout layout = new RelativeLayout();
    layout.SetBinding( Layout.BackgroundColorProperty, new Binding( "BackgroundColor" ) );

    View = Layout;
  }
}

代码示例来源:origin: wildfly/wildfly

} else {
  final Object binding = lookup(name.toString(), child, true);
  results.add(new Binding(childParts[childParts.length - 1], binding));
results.add(new Binding(contextName, new NamingContext(((Name) name.clone()).add(contextName), this, null)));

代码示例来源:origin: apache/geode

while (iterat.hasNext()) {
 String bindingName = (String) iterat.next();
 bindings.addElement(new Binding(bindingName, ctxMaps.get(bindingName)));

代码示例来源:origin: wildfly/wildfly

javax.naming.Binding jbndg = new javax.naming.Binding(cnameStr, obj);

代码示例来源:origin: wildfly/wildfly

prefix.add(relName);
  final RelativeFederatingContext context = new RelativeFederatingContext(new FastHashtable<String, Object>(remoteContext.getEnvironment()), remoteContext, prefix);
  results.add(new Binding(relName, context, true));
} else if (b == Protocol.P_BINDING) {
  results.add(unmarshaller.readObject(Binding.class));

代码示例来源:origin: mulesoft/mule

public Object nextElement() {
  Map.Entry entry = getNext();
  return new Binding((String) entry.getKey(), entry.getValue());
 }
}

代码示例来源:origin: stackoverflow.com

public void exec(File file, OutputStream output) throws Exception {
  Binding binding = new Binding()
  binding.setProperty("out", new PrintStream(output)) 
  GroovyShell shell = new GroovyShell(binding);
  shell.evaluate(file);
}

代码示例来源:origin: stackoverflow.com

public void exec(File file, OutputStream output) throws Exception {
  Binding binding = new Binding()
  binding.setProperty("out", output) 
  GroovyShell shell = new GroovyShell(binding);
  shell.evaluate(file);
}

代码示例来源:origin: crashub/crash

@Override
 public NamingEnumeration<Binding> listBindings(String name) throws NamingException {
  if (name == "") {
   List<Binding> l = new ArrayList<Binding>();
   l.add(new Binding("String", "Bar", ""));
   l.add(new Binding("ArrayList", "Bar", new ArrayList()));
   return new Bindings(l);
  } else {
   throw new NamingException();
  }
 }
}

代码示例来源:origin: crashub/crash

@Override
 public NamingEnumeration<Binding> listBindings(String name) throws NamingException {
  if (name.startsWith("java:global") || name == "") {
   List<Binding> l = new ArrayList<Binding>();
   l.add(new Binding("Foo", "Bar", ""));
   return new Bindings(l);
  } else {
   throw new NamingException();
  }
 }
}

代码示例来源:origin: crashub/crash

@Override
 public NamingEnumeration<Binding> listBindings(String name) throws NamingException {

  if (name.startsWith("java:global")) {
   List<Binding> l = new ArrayList<Binding>();
   l.add(new Binding("Foo", "Bar", ""));
   l.add(new Binding("Foo2", "Bar2", new SimpleContext()));
   return new Bindings(l);
  } else {
   throw new NamingException();
  }
 }
}

相关文章