Class OldSysCustomerMgr

java.lang.Object
de.calamanari.pk.wrapper.legacy.OldSysCustomerMgr
Direct Known Subclasses:
OldSysCustomerMgrMock

public class OldSysCustomerMgr
extends java.lang.Object
OldSys Customer Manager - part of the fictional legacy system, we want to create a WRAPPER for.
This class provides access to the customer database.
Author:
Karl Eilebrecht
  • Field Summary

    Fields
    Modifier and Type Field Description
    static java.lang.String[] NO_RESULT
    NULL-OBJECT to return and indicate "no result"
  • Constructor Summary

    Constructors
    Constructor Description
    OldSysCustomerMgr()  
  • Method Summary

    Modifier and Type Method Description
    int[] findCustomerByExample​(java.lang.String[] searchData)
    Returns an array of the customerIds matching the search data:
    key value
    java.lang.String[] getCustomerData​(int customerId)
    Returns an array with customer record:
    key value

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • NO_RESULT

      public static final java.lang.String[] NO_RESULT
      NULL-OBJECT to return and indicate "no result"
  • Constructor Details

  • Method Details

    • getCustomerData

      public java.lang.String[] getCustomerData​(int customerId)
      Returns an array with customer record:
      • key
      • value
      Parameters:
      customerId - identifier
      Returns:
      array with customer data or NO_RESULT if not found
    • findCustomerByExample

      public int[] findCustomerByExample​(java.lang.String[] searchData)
      Returns an array of the customerIds matching the search data:
      • key
      • value
      Parameters:
      searchData - array with customer data to search for
      Returns:
      array of customerIds or empty array NEVER NULL