use of eu.ggnet.dwoss.receipt.stub.ProductProcessorStub in project dwoss by gg-net.
the class EditCpuPanel method main.
// End of variables declaration//GEN-END:variables
public static void main(String[] args) throws Exception {
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
Cpu cpu = new Cpu(Cpu.Series.CORE_I7, "930", Cpu.Type.DESKTOP, 3.00, 4);
EditCpuPanel view = new EditCpuPanel(new ProductProcessorStub(), new ArrayList<Cpu>());
view.setCpu(cpu);
OkCancelDialog<EditCpuPanel> create = new OkCancelDialog<>("Spezifikationen", view);
create.setVisible(true);
if (create.getCloseType() == CloseType.OK) {
System.out.println(view.getCpu());
}
System.exit(0);
}
use of eu.ggnet.dwoss.receipt.stub.ProductProcessorStub in project dwoss by gg-net.
the class DesktopBundleViewTryout method tryoutView.
@Test
public void tryoutView() throws InterruptedException {
final ProductSpec spec = new SpecGenerator().makeSpec();
DesktopBundleView view = new DesktopBundleView(new Mandators() {
@Override
public Mandator loadMandator() {
return Mandator.builder().defaultMailSignature(null).smtpConfiguration(null).mailTemplateLocation(null).company(CompanyGen.makeCompany()).dossierPrefix("DW").documentIntermix(null).documentIdentifierGeneratorConfigurations(new EnumMap<>(DocumentType.class)).build();
}
@Override
public DefaultCustomerSalesdata loadSalesdata() {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("loadSalesdata - Not supported yet.");
}
@Override
public ReceiptCustomers loadReceiptCustomers() {
return ReceiptCustomers.builder().build();
}
@Override
public SpecialSystemCustomers loadSystemCustomers() {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("loadSystemCustomers - Not supported yet.");
}
@Override
public Contractors loadContractors() {
return new Contractors(EnumSet.of(TradeName.ALSO, TradeName.ACER), EnumSet.of(TradeName.ACER));
}
@Override
public PostLedger loadPostLedger() {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("loadPostLedger - Not supported yet.");
}
@Override
public ShippingTerms loadShippingTerms() {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("loadShippingTerms - Not supported yet.");
}
}, new SpecAgent() {
@Override
public ProductSpec findProductSpecByPartNoEager(String partNo) {
if (partNo == null)
return null;
if (partNo.startsWith("X"))
return null;
spec.setPartNo(partNo);
return spec;
}
// <editor-fold defaultstate="collapsed" desc="Unneeded Methods">
@Override
public <T> long count(Class<T> entityClass) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> List<T> findAll(Class<T> entityClass) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> List<T> findAll(Class<T> entityClass, int start, int amount) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> List<T> findAllEager(Class<T> entityClass) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> List<T> findAllEager(Class<T> entityClass, int start, int amount) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> T findById(Class<T> entityClass, Object id) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> T findById(Class<T> entityClass, Object id, LockModeType lockModeType) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> T findByIdEager(Class<T> entityClass, Object id) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
@Override
public <T> T findByIdEager(Class<T> entityClass, Object id, LockModeType lockModeType) {
// To change body of generated methods, choose Tools | Templates.
throw new UnsupportedOperationException("Not supported yet.");
}
}, new ProductProcessorStub(), TradeName.ACER, TradeName.ACER, ProductGroup.DESKTOP, ProductGroup.MONITOR);
view.setSpec(new DesktopBundle());
OkCancelDialog<DesktopBundleView> dialog = new OkCancelDialog<>("BundleView", view);
dialog.setVisible(true);
dialog.dispose();
}
use of eu.ggnet.dwoss.receipt.stub.ProductProcessorStub in project dwoss by gg-net.
the class MonitorView method main.
// End of variables declaration//GEN-END:variables
public static void main(String[] args) throws Exception {
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
ProductProcessorStub stub = new ProductProcessorStub();
MonitorView view = new MonitorView();
view.setSpec(stub.monitor);
OkCancelDialog<MonitorView> create = new OkCancelDialog("Display Details", view);
create.setVisible(true);
System.out.println(create.getSubContainer().getSpec());
System.exit(0);
}
use of eu.ggnet.dwoss.receipt.stub.ProductProcessorStub in project dwoss by gg-net.
the class SpecListPanel method main.
// End of variables declaration//GEN-END:variables
public static void main(String[] args) {
SpecListController controller;
ProductProcessorStub stub = new ProductProcessorStub();
controller = new SpecListController(stub.getSpecAgentStub());
OkCancelDialog<SpecListPanel> panel = new OkCancelDialog<>("blub", new SpecListPanel(controller));
panel.setVisible(true);
System.exit(0);
}
use of eu.ggnet.dwoss.receipt.stub.ProductProcessorStub in project dwoss by gg-net.
the class CpuListPanel method main.
// End of variables declaration//GEN-END:variables
public static void main(String[] args) {
CpuListController controller;
ProductProcessorStub stub = new ProductProcessorStub();
controller = new CpuListController(stub.getSpecAgentStub());
OkCancelDialog<CpuListPanel> panel = new OkCancelDialog<>("blub", new CpuListPanel(controller));
panel.setVisible(true);
System.exit(0);
}
Aggregations