Examples of toLocalTime()


Examples of org.threeten.bp.OffsetTime.toLocalTime()

        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        402, 402, 122, 122, BigDecimal.valueOf(100.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "JMP", "B", "402");
    tradeTime = _now.toOffsetTime().minusSeconds(403);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        403, 403, 122, 122, BigDecimal.valueOf(22.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "CISC", "B", "403");
    tradeTime = _now.toOffsetTime().minusSeconds(404);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        404, 404, 123, 123, BigDecimal.valueOf(100.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C104", "B", "404");
    tradeTime = _now.toOffsetTime().minusSeconds(405);
View Full Code Here

Examples of org.threeten.bp.OffsetTime.toLocalTime()

        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        403, 403, 122, 122, BigDecimal.valueOf(22.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "CISC", "B", "403");
    tradeTime = _now.toOffsetTime().minusSeconds(404);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        404, 404, 123, 123, BigDecimal.valueOf(100.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C104", "B", "404");
    tradeTime = _now.toOffsetTime().minusSeconds(405);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        405, 405, 123, 123, BigDecimal.valueOf(200.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C105", "B", "405");
    tradeTime = _now.toOffsetTime().minusSeconds(406);
View Full Code Here

Examples of org.threeten.bp.OffsetTime.toLocalTime()

        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        404, 404, 123, 123, BigDecimal.valueOf(100.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C104", "B", "404");
    tradeTime = _now.toOffsetTime().minusSeconds(405);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        405, 405, 123, 123, BigDecimal.valueOf(200.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C105", "B", "405");
    tradeTime = _now.toOffsetTime().minusSeconds(406);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        406, 406, 123, 123, BigDecimal.valueOf(300.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C106", "B", "406");
    tradeTime = _now.toOffsetTime().minusSeconds(407);
View Full Code Here

Examples of org.threeten.bp.OffsetTime.toLocalTime()

        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        405, 405, 123, 123, BigDecimal.valueOf(200.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C105", "B", "405");
    tradeTime = _now.toOffsetTime().minusSeconds(406);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        406, 406, 123, 123, BigDecimal.valueOf(300.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C106", "B", "406");
    tradeTime = _now.toOffsetTime().minusSeconds(407);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        407, 407, 221, 221, BigDecimal.valueOf(221.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C221", "B", "407");
    tradeTime = _now.toOffsetTime().minusSeconds(408);
View Full Code Here

Examples of org.threeten.bp.OffsetTime.toLocalTime()

        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        406, 406, 123, 123, BigDecimal.valueOf(300.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C106", "B", "406");
    tradeTime = _now.toOffsetTime().minusSeconds(407);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        407, 407, 221, 221, BigDecimal.valueOf(221.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C221", "B", "407");
    tradeTime = _now.toOffsetTime().minusSeconds(408);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        408, 407, 222, 221, BigDecimal.valueOf(222.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C222", "B", "408");
View Full Code Here

Examples of org.threeten.bp.OffsetTime.toLocalTime()

        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        407, 407, 221, 221, BigDecimal.valueOf(221.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C221", "B", "407");
    tradeTime = _now.toOffsetTime().minusSeconds(408);
    template.update("INSERT INTO pos_trade (id, oid, position_id, position_oid, quantity, trade_date, trade_time, zone_offset, cparty_scheme, cparty_value, provider_scheme, provider_value) " +
        "VALUES(?,?,?,?,?,?,?,?,?,?,?,?)",
        408, 407, 222, 221, BigDecimal.valueOf(222.987), toSqlDate(_now.toLocalDate()), toSqlTimestamp(tradeTime.toLocalTime()), tradeTime.getOffset().getTotalSeconds(), "CPARTY", "C222", "B", "408");

    template.update("INSERT INTO pos_trade2idkey VALUES (?,?)", 400, 501);
    template.update("INSERT INTO pos_trade2idkey VALUES (?,?)", 401, 502);
    template.update("INSERT INTO pos_trade2idkey VALUES (?,?)", 401, 503);
    template.update("INSERT INTO pos_trade2idkey VALUES (?,?)", 402, 504);
View Full Code Here

Examples of org.threeten.bp.ZonedDateTime.toLocalTime()

    // Test Serialization of ISO via chrono API
    //-----------------------------------------------------------------------
    @Test( dataProvider="calendars")
    public void test_ChronoZonedDateTimeSerialization(Chronology chrono) throws Exception {
        ZonedDateTime ref = LocalDate.of(2000, 1, 5).atTime(12, 1, 2, 3).atZone(ZoneId.of("GMT+01:23"));
        ChronoZonedDateTime<?> orginal = chrono.date(ref).atTime(ref.toLocalTime()).atZone(ref.getZone());
        ByteArrayOutputStream baos = new ByteArrayOutputStream();
        ObjectOutputStream out = new ObjectOutputStream(baos);
        out.writeObject(orginal);
        out.close();
        ByteArrayInputStream bais = new ByteArrayInputStream(baos.toByteArray());
View Full Code Here

Examples of org.threeten.bp.ZonedDateTime.toLocalTime()

    final boolean eom = indexConvention.isIsEOM();
    final int spotLag = indexConvention.getSettlementDays();
    final IborIndex iborIndex = new IborIndex(currency, indexTenor, spotLag, dayCount, businessDayConvention, eom, indexConvention.getName());
    final ExchangeTradedInstrumentExpiryCalculator expiryCalculator = ExchangeTradedInstrumentExpiryCalculatorFactory.getCalculator(expiryCalculatorName);
    final ZonedDateTime startDate = _valuationTime.plus(rateFuture.getStartTenor().getPeriod());
    final LocalTime time = startDate.toLocalTime();
    final ZoneId timeZone = startDate.getZone();
    final ZonedDateTime expiryDate = ZonedDateTime.of(expiryCalculator.getExpiryDate(rateFuture.getFutureNumber(), startDate.toLocalDate(), regionCalendar), time, timeZone);
    final InterestRateFutureSecurityDefinition securityDefinition = new InterestRateFutureSecurityDefinition(expiryDate, iborIndex, 1, paymentAccrualFactor, "", fixingCalendar);
    final InterestRateFutureTransactionDefinition transactionDefinition = new InterestRateFutureTransactionDefinition(securityDefinition, _valuationTime, price, 1);
    //return transactionDefinition;
View Full Code Here

Examples of org.threeten.bp.ZonedDateTime.toLocalTime()

    final IndexON index = new IndexON(indexConvention.getName(), currency, dayCount, publicationLag);
    final double paymentAccrualFactor = 1 / 12.;
    final Calendar calendar = CalendarUtils.getCalendar(_regionSource, _holidaySource, indexConvention.getRegionCalendar());
    final ExchangeTradedInstrumentExpiryCalculator expiryCalculator = ExchangeTradedInstrumentExpiryCalculatorFactory.getCalculator(expiryCalculatorName);
    final ZonedDateTime startDate = _valuationTime.plus(rateFuture.getStartTenor().getPeriod());
    final LocalTime time = startDate.toLocalTime();
    final ZoneId timeZone = startDate.getZone();
    final ZonedDateTime expiryDate = ZonedDateTime.of(expiryCalculator.getExpiryDate(rateFuture.getFutureNumber(), startDate.toLocalDate(), calendar), time, timeZone);
    final FederalFundsFutureSecurityDefinition securityDefinition = FederalFundsFutureSecurityDefinition.from(expiryDate,
                                                                                                              index, 1, paymentAccrualFactor, "", calendar);
    final FederalFundsFutureTransactionDefinition transactionDefinition = new FederalFundsFutureTransactionDefinition(securityDefinition, 1, _valuationTime, price);
View Full Code Here

Examples of org.threeten.bp.ZonedDateTime.toLocalTime()

    final VanillaIborLegConvention iborLegConvention = (VanillaIborLegConvention) receiveLegConvention;
    final String expiryCalculatorName = futureConvention.getExpiryConvention().getValue();
    final ZonedDateTime startDate = _valuationTime.plus(swapFuture.getStartTenor().getPeriod());
    final Calendar calendar = CalendarUtils.getCalendar(_regionSource, _holidaySource, futureConvention.getExchangeCalendar());
    final ExchangeTradedInstrumentExpiryCalculator expiryCalculator = ExchangeTradedInstrumentExpiryCalculatorFactory.getCalculator(expiryCalculatorName);
    final LocalTime time = startDate.toLocalTime();
    final ZoneId timeZone = startDate.getZone();
    final double notional = 1.0;
    final int spotLagSwap = fixedLegConvention.getSettlementDays();
    final ZonedDateTime lastTradeDate = ZonedDateTime.of(expiryCalculator.getExpiryDate(swapFuture.getFutureNumber(), startDate.toLocalDate(), calendar), time, timeZone);
    final ZonedDateTime deliveryDate = ScheduleCalculator.getAdjustedDate(lastTradeDate, spotLagSwap, calendar);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.