congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
SpaceFactory.getSpace
Code IndexAdd Tabnine to your IDE (free)

How to use
getSpace
method
in
org.jpos.space.SpaceFactory

Best Java code snippets using org.jpos.space.SpaceFactory.getSpace (Showing top 20 results out of 315)

origin: jpos/jPOS

/**
 * @return the default TransientSpace
 */
public static Space getSpace () {
  return getSpace (TSPACE, DEFAULT, null);
}
origin: jpos/jPOS

private Space grabSpace (Element e)
 throws ConfigurationException
{
  String uri = e != null ? e.getText() : "";
  return SpaceFactory.getSpace (uri);
}
origin: jpos/jPOS

@SuppressWarnings("unchecked")
private Space<String, Object> grabSpace(Element e)
{
  return (Space<String, Object>) SpaceFactory.getSpace(e != null ? e.getText() : "");
}
origin: jpos/jPOS

@SuppressWarnings("unchecked")
private Space<String,Object> grabSpace (Element e) {
  return (Space<String,Object>) SpaceFactory.getSpace (e != null ? e.getText() : "");
}
origin: jpos/jPOS

public SpaceProxy () throws RemoteException {
  super();
  sp = SpaceFactory.getSpace ();
  startService ();
}
public SpaceProxy (String spaceUri) throws RemoteException {
origin: jpos/jPOS

public SpaceProxy (String spaceUri) throws RemoteException {
  super ();
  sp = SpaceFactory.getSpace (spaceUri);
  startService ();
}
origin: jpos/jPOS

protected void startService () throws Exception {
  if (spaceName == null) 
    sp = SpaceFactory.getSpace ();
  else 
    sp = SpaceFactory.getSpace (spaceName);
  objectName = new ObjectName (Q2.QBEAN_NAME + 
    getName() + ",space=" +
    (spaceName != null ? spaceName : "default")
  );
  getServer().getMBeanServer().registerMBean (sp, objectName);
}
origin: jpos/jPOS

private LocalSpace grabSpace (Element e) throws ConfigurationException
{
  String uri = e != null ? e.getText() : "";
  Space sp = SpaceFactory.getSpace (uri);
  if (sp instanceof LocalSpace) {
    return (LocalSpace) sp;
  }
  throw new ConfigurationException ("Invalid space " + uri);
}
origin: jpos/jPOS

private LocalSpace grabSpace (Element e) 
  throws ConfigurationException
{
  String uri = e != null ? e.getText() : "";
  Space sp = SpaceFactory.getSpace (uri);
  if (sp instanceof LocalSpace) {
    return (LocalSpace) sp;
  }
  throw new ConfigurationException ("Invalid space " + uri);
}
origin: jpos/jPOS

@Test(expected = NullPointerException.class)
public void testGetSpaceThrowsNullPointerException2() throws Throwable {
SpaceFactory.getSpace("testSpaceFactoryScheme", "testSpaceFactoryName",
  null);
}
origin: jpos/jPOS

  public void setConfiguration (Configuration cfg) 
    throws ConfigurationException
  {
    sp = SpaceFactory.getSpace(cfg.get ("space", ""));
    queue = cfg.get ("queue", null);
    if (queue == null)
      throw new ConfigurationException ("Unspecified queue");
    timeout = cfg.getLong ("timeout", 60000L);
  }
}
origin: jpos/jPOS

public void testGetSpaceThrowsNullPointerException1() throws Throwable {
try {
  SpaceFactory.getSpace("testSpaceFactoryScheme",
    "testSpaceFactoryName", "testSpaceFactoryParam");
  fail("Expected NullPointerException to be thrown");
} catch (NullPointerException ex) {
  assertNull("ex.getMessage()", ex.getMessage());
}
}
origin: jpos/jPOS

  public void setUp () throws Exception {
    sp = SpaceFactory.getSpace("tspace:txnmgrtest");
    q2 = new Q2("build/resources/test/org/jpos/transaction");
    q2.start();
  }
//    public void testSimpleTransaction() {
origin: jpos/jPOS

  @Override
  public void setConfiguration (Configuration cfg) throws ConfigurationException {
    super.setConfiguration(cfg);
    queueName = cfg.get("queue", null);
    if (queueName == null)
      throw new ConfigurationException("'queue' property not configured");
    sp = SpaceFactory.getSpace(cfg.get("space"));
    timeout = cfg.getLong("timeout", timeout);
  }
}
origin: jpos/jPOS

@Test
public void testGetSpace2() throws Throwable {
TSpace result = (TSpace) SpaceFactory.getSpace("testString");
assertTrue("result.isEmpty()", result.isEmpty());
}
origin: jpos/jPOS

private static Element createSchema() {
  Element schema = new Element("schema");
  schema.setAttribute("id","base");
  SpaceFactory.getSpace().put(SCHEMA_PREFIX+"base.xml", schema);
  return schema;
}
origin: jpos/jPOS

@Test
public void testWipe1() throws Throwable {
  SpaceUtil.wipe(SpaceFactory.getSpace(), "");
  assertTrue("Test completed without Exception", true);
  // dependencies on static and environment state led to removal of 1
  // assertion
}
origin: jpos/jPOS

@Test
public void testInpAll1() throws Throwable {
  Space sp = SpaceFactory.getSpace("testSpaceUtilSpaceUri");
  SpaceUtil.nextLong(sp, "");
  Object[] result = SpaceUtil.inpAll(sp, "");
  assertEquals("(TSpace) sp.entries.size()", 0, ((TSpace) sp).entries.size());
  assertFalse("(TSpace) sp.entries.containsKey(\"\")", ((TSpace) sp).entries.containsKey(""));
  assertEquals("result.length", 1, result.length);
  assertEquals("result[0]", 1L, result[0]);
}
origin: jpos/jPOS

@Test
public void testRdp() throws Throwable {
  Space sp = SpaceFactory.getSpace();
  SpaceInterceptor spaceInterceptor = new SpaceInterceptor(sp);
  Object result = spaceInterceptor.rdp(sp);
  assertNull("result", result);
  assertSame("spaceInterceptor.sp", sp, spaceInterceptor.sp);
}
origin: jpos/jPOS-EE

@BeforeClass
public static void setUp() {
  RestAssured.baseURI = APITest.BASE_URL;
  RestAssured.requestSpecification = new RequestSpecBuilder().build().contentType(MediaType.APPLICATION_JSON);
  sp = SpaceFactory.getSpace();
  if (sp.rdp ("JPOSEE:STARTED") == null) {
    System.setProperty("user.name", "admin");
    q2 = new Q2();
    q2.start();
  }
  ISOUtil.sleep(5000);
}
org.jpos.spaceSpaceFactorygetSpace

Popular methods of SpaceFactory

  • <init>
  • createSpace
  • getGCExecutor
  • normalize

Popular in Java

  • Finding current android device location
  • notifyDataSetChanged (ArrayAdapter)
  • getSupportFragmentManager (FragmentActivity)
  • getApplicationContext (Context)
  • Color (java.awt)
    The Color class is used to encapsulate colors in the default sRGB color space or colors in arbitrary
  • Graphics2D (java.awt)
    This Graphics2D class extends the Graphics class to provide more sophisticated control overgraphics
  • Timer (java.util)
    Timers schedule one-shot or recurring TimerTask for execution. Prefer java.util.concurrent.Scheduled
  • Filter (javax.servlet)
    A filter is an object that performs filtering tasks on either the request to a resource (a servlet o
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
  • From CI to AI: The AI layer in your organization
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now