Java Second Convert toNanoseconds(long sec, long nanos)

Here you can find the source of toNanoseconds(long sec, long nanos)

Description

to Nanoseconds

License

Open Source License

Declaration

public static long toNanoseconds(long sec, long nanos) 

Method Source Code

//package com.java2s;
/*******************************************************************************
 * Copyright (c) 2009  Clark N. Hobbie/*from w ww . ja  va 2  s  .com*/
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     Clark N. Hobbie - initial API and implementation
 *******************************************************************************/

public class Main {
    public static long toNanoseconds(long sec, long nanos) {
        long result = nanos;
        result = result + 1000000000 * sec;
        return result;
    }
}

Related

  1. SecondToMin(double asec)
  2. timeStringToSeconds(String str)
  3. toCentiSeconds(float t)
  4. toDaySecondDifference(long difference)
  5. toHhMmSs(long seconds)
  6. toSeconds(double value)
  7. toSeconds(long date)
  8. toSeconds(long millis)
  9. toSeconds(long milliseconds)