/*
 * Copyright (c) 2004, 2005, ADAPT project partners (IST-2001-37126).
 * 
 * PurchaseOrderBean.java
 */

package org.eu.adapt.demonstrator.eb.manufacturer;

import java.util.Collection;
import javax.ejb.CreateException;
import javax.ejb.EntityContext;
import javax.ejb.EntityBean;

public abstract class PurchaseOrderBean implements EntityBean
{
    public String ejbCreate(String orderNumber, CustomerLocal customer, float total)
        throws CreateException
    {
        setOrderNumber(orderNumber);
        setTotal(total);
        
        return null;
    }

    public void ejbPostCreate(String orderNumber, CustomerLocal customer, float total)
    {
        setCustomer(customer);
    }

    public abstract void setOrderNumber(String orderNumber);

    public abstract String getOrderNumber();

    public abstract void setTotal(float total);

    public abstract float getTotal();

    public abstract void setCustomer(CustomerLocal customer);

    public abstract CustomerLocal getCustomer();

    public abstract void setItems(Collection items);

    public abstract Collection getItems();

    public void setEntityContext(EntityContext entityContext)
    {
    }

    public void unsetEntityContext()
    {
    }

    public void ejbActivate()
    {
    }

    public void ejbPassivate()
    {
    }

    public void ejbLoad()
    {
    }

    public void ejbStore()
    {
    }    

    public void ejbRemove()
    {
    }
}
