Codota Logo
Case
Code IndexAdd Codota to your IDE (free)

How to use
Case
in
com.ning.billing.catalog.rules

Best Java code snippets using com.ning.billing.catalog.rules.Case (Showing top 6 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
BufferedReader b =
  • Codota IconInputStream in;new BufferedReader(new InputStreamReader(in))
  • Codota IconReader in;new BufferedReader(in)
  • Codota IconFile file;new BufferedReader(new FileReader(file))
  • Smart code suggestions by Codota
}
origin: com.ning.billing/killbill-catalog

public T getResult(final PlanSpecifier planPhase, final StandaloneCatalog c) throws CatalogApiException {
  if (satisfiesCase(planPhase, c)) {
    return getResult();
  }
  return null;
}
origin: com.ning.billing/killbill-catalog

protected boolean satisfiesCase(final PlanSpecifier planPhase, final StandaloneCatalog c) throws CatalogApiException {
  return (getProduct() == null || getProduct().equals(c.findCurrentProduct(planPhase.getProductName()))) &&
      (getProductCategory() == null || getProductCategory().equals(planPhase.getProductCategory())) &&
      (getBillingPeriod() == null || getBillingPeriod().equals(planPhase.getBillingPeriod())) &&
      (getPriceList() == null || getPriceList().equals(c.findCurrentPriceList(planPhase.getPriceListName())));
}
origin: com.ning.billing/killbill-catalog

public static <K> K getResult(final Case<K>[] cases, final PlanSpecifier planSpec, final StandaloneCatalog catalog) throws CatalogApiException {
  if (cases != null) {
    for (final Case<K> c : cases) {
      final K result = c.getResult(planSpec, catalog);
      if (result != null) {
        return result;
      }
    }
  }
  return null;
}
origin: com.ning.billing/killbill-catalog

public PlanAlignmentCreate getPlanCreateAlignment(final PlanSpecifier specifier, final StandaloneCatalog catalog) throws CatalogApiException {
  return Case.getResult(createAlignmentCase, specifier, catalog);
}
origin: com.ning.billing/killbill-catalog

private DefaultPriceList findPriceList(final PlanSpecifier specifier, final StandaloneCatalog catalog) throws CatalogApiException {
  DefaultPriceList result = Case.getResult(priceListCase, specifier, catalog);
  if (result == null) {
    result = catalog.findCurrentPriceList(specifier.getPriceListName());
  }
  return result;
}
origin: com.ning.billing/killbill-catalog

    Result.LALA);
final Result r1 = Case.getResult(new CaseResult[]{cr0, cr1, cr2, cr3},
                 new PlanSpecifier(product.getName(), product.getCategory(), BillingPeriod.MONTHLY, priceList.getName()), cat);
Assert.assertEquals(r1, Result.FOO);
final Result r2 = Case.getResult(new CaseResult[]{cr0, cr1, cr2},
                 new PlanSpecifier(product.getName(), product.getCategory(), BillingPeriod.ANNUAL, priceList.getName()), cat);
Assert.assertEquals(r2, Result.DIPSY);
com.ning.billing.catalog.rulesCase

Most used methods

  • getResult
  • getBillingPeriod
  • getPriceList
  • getProduct
  • getProductCategory
  • satisfiesCase

Popular in Java

  • Making http post requests using okhttp
  • compareTo (BigDecimal)
  • getResourceAsStream (ClassLoader)
    Returns a stream for the resource with the specified name. See #getResource(String) for a descriptio
  • orElseThrow (Optional)
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • FileInputStream (java.io)
    A FileInputStream obtains input bytes from a file in a file system. What files are available depends
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • Stream (java.util.stream)
    A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
  • Get (org.apache.hadoop.hbase.client)
    Used to perform Get operations on a single row. To get everything for a row, instantiate a Get objec
  • IsNull (org.hamcrest.core)
    Is the value null?
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now