Package com.opengamma.financial.generator

Examples of com.opengamma.financial.generator.StaticNameGenerator


  @Override
  public PortfolioNodeGenerator createPortfolioNodeGenerator(final int portfolioSize) {
    final SecurityGenerator<SwapSecurity> securities = createSwapSecurityGenerator();
    configure(securities);
    final PositionGenerator positions = new SimplePositionGenerator<>(securities, getSecurityPersister(), getCounterPartyGenerator());
    return new LeafPortfolioNodeGenerator(new StaticNameGenerator("Swaps"), positions, 4);
  }
View Full Code Here


  @Override
  public PortfolioGenerator createPortfolioGenerator(final NameGenerator portfolioNameGenerator) {
    final SecurityGenerator<FXOptionSecurity> securities = createFXOptionSecurityGenerator();
    configure(securities);
    final PositionGenerator positions = new SimplePositionGenerator<>(securities, getSecurityPersister(), getCounterPartyGenerator());
    final PortfolioNodeGenerator rootNode = new LeafPortfolioNodeGenerator(new StaticNameGenerator("FX Options"), positions, FX_OPTIONS.size());
    return new PortfolioGenerator(rootNode, portfolioNameGenerator);
  }
View Full Code Here

  @Override
  public PortfolioNodeGenerator createPortfolioNodeGenerator(final int portfolioSize) {
    final SecurityGenerator<FXOptionSecurity> securities = createFXOptionSecurityGenerator();
    configure(securities);
    final PositionGenerator positions = new SimplePositionGenerator<>(securities, getSecurityPersister(), getCounterPartyGenerator());
    return new LeafPortfolioNodeGenerator(new StaticNameGenerator("FX Options"), positions, FX_OPTIONS.size());
  }
View Full Code Here

    }
  }

  private SyntheticPortfolioGeneratorTool portfolioGeneratorTool() {
    final SyntheticPortfolioGeneratorTool tool = new SyntheticPortfolioGeneratorTool();
    tool.setCounterPartyGenerator(new StaticNameGenerator(AbstractPortfolioGeneratorTool.DEFAULT_COUNTER_PARTY));
    return tool;
  }
View Full Code Here

    final MySecurityGenerator<ManageableSecurity> fourthGenerator = getSwaptionParityGenerator(securityMaster);
    configure(firstGenerator);
    configure(secondGenerator);
    configure(thirdGenerator);
    configure(fourthGenerator);
    final TreePortfolioNodeGenerator rootNode = new TreePortfolioNodeGenerator(new StaticNameGenerator("Swap / Swaption Portfolio"));
    rootNode.addChildNode(firstGenerator);
    rootNode.addChildNode(secondGenerator);
    rootNode.addChildNode(thirdGenerator);
    rootNode.addChildNode(fourthGenerator);
    return rootNode;
View Full Code Here

TOP

Related Classes of com.opengamma.financial.generator.StaticNameGenerator

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.