Class PAccountInfoBeanImpl

java.lang.Object
com.portal.app.cc.comp.PAccountInfoBeanImpl

public class PAccountInfoBeanImpl extends Object
Used to determine paying relationships for accounts
Version:
%version: 17 % %date_modified: Fri Apr 05 13:41:26 2002 %
Author:
kapono
  • Constructor Details

  • Method Details

    • isSubordinate

      public boolean isSubordinate(PModelHandle p)
      Determines if the given account is subordinate to another account
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      true if this account is subordinate, false otherwise
    • isSponsor

      public boolean isSponsor(PModelHandle hAccount)
      Determines if the given account is a owner of at lease one sponsor group return true if hAccount is a sponsor, return false otherwise.
      Parameters:
      pAccount -
    • hasChildren

      public boolean hasChildren(PModelHandle p)
      Determines if the given account has subordinate children
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      true if this account has children, false otherwise
    • hasChildrenAll

      public void hasChildrenAll(Hashtable<Poid,Boolean> hChildrenInfo, FList flBillInfos)
      Determines if the given account has subordinate children
      Parameters:
      hChildrenInfo - result will be filled here.
      flBillInfos - , FList of bill infos.
    • getBalanceGroupCount

      public int getBalanceGroupCount(Poid billinfoPoid)
      Return the balance group count for the passed in bill info
      Parameters:
      billinfoPoid -
      Returns:
    • getBillinfoServiceCount

      public int getBillinfoServiceCount(Poid billinfoPoid, boolean isAllBillInfoSelected)
      Returns the service count for the passed in bill unit.
      Parameters:
      billinfoPoid -
      isAllBillInfoSelected -
      Returns:
    • getARBillInfo

      public PModelHandle getARBillInfo(PModelHandle p)
      Determines the parent A/R account for a subordinate account
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      the A/R account of a given account, could be itself if not a subordinate account
    • getParent

      public PModelHandle getParent(PModelHandle p)
      Determines the parent account if this account is in a hierarchy
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      the parent account if this account is part of a hierarchy, null otherwise
    • isBrandAccount

      public boolean isBrandAccount(Poid acctPoid) throws RemoteException
      Throws:
      RemoteException
    • getAccountCurrency

      public int[] getAccountCurrency(PModelHandle p) throws PInfranetException
      Used to retrieve the primary and secondary currencies (as ints) for the given account. These int values can be later passed to the BEID manager for lookup/conversion.
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      An array containing the primary and secondary currencies for this account. If the value for secondary is zero, there is no secondary currency for this account.
      Throws:
      PInfranetException
    • getDb

      public long getDb(PModelHandle p)
      Retrieves the database number where this account resides
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      the database number or -1 if p is null or if there is an error.
    • getBrand

      public PScopeEntryPoint getBrand(PModelHandle p) throws PInfranetException
      Retrieves the brand for this account
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      the brand if this account is branded null otherwise
      Throws:
      PInfranetException
    • getAccountPoid

      public Poid getAccountPoid(PModelHandle pm)
      Method which returns the default account poid
      Returns:
      Poid type ,which is the default account Poid
    • getBillInfosOnly

      public Vector<FList> getBillInfosOnly(PModelHandle p)
      Method which returns the billInfos
      Returns:
      Vector type ,which returns the billinfos
    • hasPendingBill

      public boolean hasPendingBill(PModelHandle p)
      Method which returns true only when there is a pending bill due for an account
      Returns:
      boolean type ,which returns true/false
    • getTotalPendingBillDue

      public BigDecimal getTotalPendingBillDue(PModelHandle p)
      Method which returns the total pending bill due for an account
      Returns:
      BigDecimal type ,which returns the total pending bill due
    • getTotalOpenBillDue

      public BigDecimal getTotalOpenBillDue(PModelHandle p)
      Method which returns the total open bill due for an account
      Returns:
      BigDecimal type ,which returns the total open bill due
    • getTotalDueNow

      public double getTotalDueNow(PModelHandle acctModel)
      Method which returns the total due amount of the account including the child accounts
      Parameters:
      acctModel - PModelHandle, account model handle
      Returns:
      BigDecimal type ,which returns the total amount due for the account
    • getTotalOpenAndPendingBillDues

      public BigDecimal[] getTotalOpenAndPendingBillDues(PModelHandle p)
      Method which returns the total pending bill due for an account
      Returns:
      BigDecimal type ,which returns the total pending bill due
    • getBillInfoPods

      public Vector<Poid> getBillInfoPods(PModelHandle p)
      Method which returns the billInfo poids
      Returns:
      Vector type ,which returns the billinfo poids
    • getAccountLocale

      public Locale getAccountLocale(PModelHandle p) throws PInfranetException
      Retrieves the Java locale for this account
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      the Java locale for this account or system locale if a corresponding Java locale doesn't exist.
      Throws:
      PInfranetException
    • getAccountInfranetLocale

      public String getAccountInfranetLocale(PModelHandle p) throws PInfranetException
      Retrieves the Portal locale for this account
      Parameters:
      p - An account object represented as a PModelHandle
      Returns:
      the Portal locale for this account.
      Throws:
      PInfranetException
    • getBillInfoData

      public Object[] getBillInfoData(PModelHandle acct)
      This method returns the Object array retVal[] with the following details. retVal[0] - boolean, This will be true if any of the account's bill unit is paying for some other bill unit. retVal[1] - HashMap, This contains BillInfo poid and FldArBillinfoObj mapping. retVal[2] - HashMap, This contains BillInfo poid and FldBillinfoId mapping.
      Parameters:
      PModelHandle - , Account model handle.
      Returns:
      Object[]
    • getAllData

      public Object[] getAllData(PModelHandle p) throws PInfranetException
      A convenience method to retrieve the parent, brand, and currencies in one shot.
      Returns:
      An array list containing the parent account, brand, and currency array.
      Throws:
      PInfranetException
    • getDefaultBalanceGroup

      public Poid getDefaultBalanceGroup()
      Returns the default balance group poid of an account.
      Returns:
      Poid
    • refresh

      public void refresh(PModelHandle p, boolean refresh)
    • reloadOpenAndPendingBillDues

      public void reloadOpenAndPendingBillDues()
      After billing we need to reload open and pending bill dues.
    • getBillPoidInThis

      public Poid getBillPoidInThis(PModelHandle pm)
    • getBillInfos

      public PModelHandle getBillInfos(PModelHandle p, boolean refresh)
    • getAccountArBillInfo

      public PModelHandle getAccountArBillInfo(PModelHandle mAccount)
    • getBillInfo

      public PModelHandle getBillInfo(PModelHandle p, Poid billobj, boolean refresh)
    • getContext

      protected PCachedContext getContext()
      Returns client context of the customer center
      Returns:
      PCachedContext
      Throws:
      RemoteException
    • hasBillHirarchy

      public boolean hasBillHirarchy()
    • retrieveSubscriptionServices

      public ArrayList<Poid> retrieveSubscriptionServices(PModelHandle hAccount) throws RemoteException
      Throws:
      RemoteException
    • disposeAllResources

      public void disposeAllResources()
      Calling this method will nullify the references, so that garbage collection will be fast.