org.opencrx.kernel.backend
Class Depots
java.lang.Object
org.opencrx.kernel.backend.AbstractImpl
org.opencrx.kernel.backend.Depots
public class Depots
- extends AbstractImpl
Constructor Summary |
protected |
Depots()
|
Method Summary |
void |
acceptCompoundBooking(CompoundBooking compoundBooking)
|
void |
assertReports(Depot depot,
short bookingStatusThreshold)
|
CompoundBooking |
cancelCompoundBooking(CompoundBooking cb,
List<String> errors)
|
void |
closeDepot(Depot depot,
Date closingDate,
List<String> errors)
|
void |
closeDepotPosition(DepotPosition depotPosition,
Date closingDate,
List<String> errors)
|
CompoundBooking |
createBookingByPosition(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
DepotPosition positionCredit,
DepotPosition positionDebit,
BookingOrigin origin,
CompoundBooking reversalOf,
List<String> errors)
|
CompoundBooking |
createBookingByPositionName(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
String positionName,
String depotNumberCredit,
Depot depotCredit,
String depotNumberDebit,
Depot depotDebit,
BookingOrigin origin,
CompoundBooking reversalOf,
List<String> errors)
|
CompoundBooking |
createBookingByProduct(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
Product product,
String depotNumberCredit,
Depot depotCredit,
String depotNumberDebit,
Depot depotDebit,
BookingOrigin origin,
CompoundBooking reversalOf,
List<String> errors)
|
CompoundBooking |
createCompoundBooking(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal[] quantities,
String[] bookingTextNames,
BookingText[] bookingTexts,
DepotPosition[] creditPositions,
DepotPosition[] debitPositions,
BookingOrigin[] origins,
CompoundBooking reversalOf,
List<String> errors)
|
CompoundBooking |
createCreditDebitBooking(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
DepotPosition positionCredit,
DepotPosition positionDebit,
BookingOrigin originIdentity,
CompoundBooking reversalOf,
List<String> errors)
|
void |
finalizeCompoundBooking(CompoundBooking cb)
|
DepotPosition |
getAndCreateDepotPosition(DepotEntity depotEntity,
String depotNumber,
Depot depot,
String positionName,
Product product,
Date openingDate)
|
Segment |
getDepotSegment(javax.jdo.PersistenceManager pm,
String providerName,
String segmentName)
|
static Depots |
getInstance()
|
boolean |
hasBookings(Path bookingElementIdentity,
javax.jdo.PersistenceManager pm)
|
void |
lockCompoundBooking(CompoundBooking cb,
short lockingReason)
|
Depot |
openDepot(DepotHolder depotHolder,
String name,
String description,
String depotNumber,
Date openingDate,
DepotType depotType,
DepotGroup depotGroup,
List<String> errors)
|
DepotPosition |
openDepotPosition(Depot depot,
String positionName,
String positionDescription,
Date openingDate,
String depotPositionQualifier,
Product product,
Boolean isLocked)
|
void |
refreshReport(Depot depot,
DepotReport report,
DepotReport reportPreviousPeriod)
|
static void |
register()
|
void |
removeCompoundBooking(CompoundBooking compoundBooking,
boolean preDelete)
|
void |
removeDepot(Depot depot,
boolean preDelete)
Remove depot. |
void |
removeDepotEntity(DepotEntity depotEntity,
boolean preDelete)
Remove depot entity. |
void |
removeDepotGroup(DepotGroup depotGroup,
boolean preDelete)
Remove depot group. |
void |
removeDepotHolder(DepotHolder depotHolder,
boolean preDelete)
Remove depot holder. |
void |
removeDepotPosition(DepotPosition depotPosition,
boolean preDelete)
Remove depot position. |
void |
removeSimpleBooking(SimpleBooking simpleBooking,
boolean preDelete)
|
void |
removeSingleBooking(SingleBooking singleBooking,
boolean preDelete)
|
void |
testForBalance(CompoundBooking cb,
BigDecimal balance,
javax.jdo.PersistenceManager pm)
|
void |
testForOpenPosition(Date valueDate,
short bookingType,
DepotPosition depotPosition)
|
void |
unlockCompoundBooking(CompoundBooking cb)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BOOKING_TYPE_STANDARD
public static final short BOOKING_TYPE_STANDARD
- See Also:
- Constant Field Values
BOOKING_TYPE_CLOSING
public static final short BOOKING_TYPE_CLOSING
- See Also:
- Constant Field Values
BOOKING_TYPE_REVERSAL
public static final short BOOKING_TYPE_REVERSAL
- See Also:
- Constant Field Values
BOOKING_STATUS_PENDING
public static final short BOOKING_STATUS_PENDING
- See Also:
- Constant Field Values
BOOKING_STATUS_FINAL
public static final short BOOKING_STATUS_FINAL
- See Also:
- Constant Field Values
DEPOT_USAGE_GOODS_ISSUE
public static final short DEPOT_USAGE_GOODS_ISSUE
- See Also:
- Constant Field Values
DEPOT_USAGE_GOODS_RETURN
public static final short DEPOT_USAGE_GOODS_RETURN
- See Also:
- Constant Field Values
DEPOT_USAGE_GOODS_DELIVERY
public static final short DEPOT_USAGE_GOODS_DELIVERY
- See Also:
- Constant Field Values
DEPOT_USAGE_WORK_EFFORT
public static final short DEPOT_USAGE_WORK_EFFORT
- See Also:
- Constant Field Values
Depots
protected Depots()
register
public static void register()
getInstance
public static Depots getInstance()
throws ServiceException
- Throws:
ServiceException
getDepotSegment
public Segment getDepotSegment(javax.jdo.PersistenceManager pm,
String providerName,
String segmentName)
- Returns:
- Returns the depot segment.
testForOpenPosition
public void testForOpenPosition(Date valueDate,
short bookingType,
DepotPosition depotPosition)
throws ServiceException
- Throws:
ServiceException
testForBalance
public void testForBalance(CompoundBooking cb,
BigDecimal balance,
javax.jdo.PersistenceManager pm)
throws ServiceException
- Throws:
ServiceException
createCreditDebitBooking
public CompoundBooking createCreditDebitBooking(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
DepotPosition positionCredit,
DepotPosition positionDebit,
BookingOrigin originIdentity,
CompoundBooking reversalOf,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
createCompoundBooking
public CompoundBooking createCompoundBooking(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal[] quantities,
String[] bookingTextNames,
BookingText[] bookingTexts,
DepotPosition[] creditPositions,
DepotPosition[] debitPositions,
BookingOrigin[] origins,
CompoundBooking reversalOf,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
getAndCreateDepotPosition
public DepotPosition getAndCreateDepotPosition(DepotEntity depotEntity,
String depotNumber,
Depot depot,
String positionName,
Product product,
Date openingDate)
throws ServiceException
- Throws:
ServiceException
createBookingByPosition
public CompoundBooking createBookingByPosition(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
DepotPosition positionCredit,
DepotPosition positionDebit,
BookingOrigin origin,
CompoundBooking reversalOf,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
createBookingByProduct
public CompoundBooking createBookingByProduct(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
Product product,
String depotNumberCredit,
Depot depotCredit,
String depotNumberDebit,
Depot depotDebit,
BookingOrigin origin,
CompoundBooking reversalOf,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
createBookingByPositionName
public CompoundBooking createBookingByPositionName(DepotEntity depotEntity,
Date valueDate,
short bookingType,
BigDecimal quantity,
String bookingTextName,
BookingText bookingText,
String positionName,
String depotNumberCredit,
Depot depotCredit,
String depotNumberDebit,
Depot depotDebit,
BookingOrigin origin,
CompoundBooking reversalOf,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
refreshReport
public void refreshReport(Depot depot,
DepotReport report,
DepotReport reportPreviousPeriod)
throws ServiceException
- Throws:
ServiceException
assertReports
public void assertReports(Depot depot,
short bookingStatusThreshold)
throws ServiceException
- Throws:
ServiceException
cancelCompoundBooking
public CompoundBooking cancelCompoundBooking(CompoundBooking cb,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
acceptCompoundBooking
public void acceptCompoundBooking(CompoundBooking compoundBooking)
throws ServiceException
- Throws:
ServiceException
finalizeCompoundBooking
public void finalizeCompoundBooking(CompoundBooking cb)
throws ServiceException
- Throws:
ServiceException
removeCompoundBooking
public void removeCompoundBooking(CompoundBooking compoundBooking,
boolean preDelete)
throws ServiceException
- Throws:
ServiceException
removeSimpleBooking
public void removeSimpleBooking(SimpleBooking simpleBooking,
boolean preDelete)
throws ServiceException
- Throws:
ServiceException
removeSingleBooking
public void removeSingleBooking(SingleBooking singleBooking,
boolean preDelete)
throws ServiceException
- Throws:
ServiceException
hasBookings
public boolean hasBookings(Path bookingElementIdentity,
javax.jdo.PersistenceManager pm)
throws ServiceException
- Throws:
ServiceException
removeDepotEntity
public void removeDepotEntity(DepotEntity depotEntity,
boolean preDelete)
throws ServiceException
- Remove depot entity. Test for existing bookings.
- Parameters:
depotEntity
- preDelete
-
- Throws:
ServiceException
removeDepotHolder
public void removeDepotHolder(DepotHolder depotHolder,
boolean preDelete)
throws ServiceException
- Remove depot holder. Test for existing bookings.
- Parameters:
depotHolder
- preDelete
-
- Throws:
ServiceException
removeDepot
public void removeDepot(Depot depot,
boolean preDelete)
throws ServiceException
- Remove depot. Test for existing bookings.
- Parameters:
depot
- preDelete
-
- Throws:
ServiceException
removeDepotPosition
public void removeDepotPosition(DepotPosition depotPosition,
boolean preDelete)
throws ServiceException
- Remove depot position. Test for existing bookings.
- Parameters:
depotPosition
- preDelete
-
- Throws:
ServiceException
removeDepotGroup
public void removeDepotGroup(DepotGroup depotGroup,
boolean preDelete)
throws ServiceException
- Remove depot group.
- Parameters:
depotGroup
- preDelete
-
- Throws:
ServiceException
openDepot
public Depot openDepot(DepotHolder depotHolder,
String name,
String description,
String depotNumber,
Date openingDate,
DepotType depotType,
DepotGroup depotGroup,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
closeDepot
public void closeDepot(Depot depot,
Date closingDate,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
openDepotPosition
public DepotPosition openDepotPosition(Depot depot,
String positionName,
String positionDescription,
Date openingDate,
String depotPositionQualifier,
Product product,
Boolean isLocked)
throws ServiceException
- Throws:
ServiceException
closeDepotPosition
public void closeDepotPosition(DepotPosition depotPosition,
Date closingDate,
List<String> errors)
throws ServiceException
- Throws:
ServiceException
lockCompoundBooking
public void lockCompoundBooking(CompoundBooking cb,
short lockingReason)
throws ServiceException
- Throws:
ServiceException
unlockCompoundBooking
public void unlockCompoundBooking(CompoundBooking cb)
throws ServiceException
- Throws:
ServiceException
This software is published under the BSD license. Copyright © 2003-2013, CRIXP AG, Switzerland, All rights reserved. Use is subject to license terms.