congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
Date.getTime
Code IndexAdd Tabnine to your IDE (free)

How to use
getTime
method
in
org.stjs.javascript.Date

Best Java code snippets using org.stjs.javascript.Date.getTime (Showing top 20 results out of 315)

origin: org.st-js/shared

  /**
   * Returns the time value associated to this <tt>Date</tt>
   * 
   * @return the time value associated to this <tt>Date</tt>
   */
  public double valueOf() {
    return getTime();
  }
}
origin: org.st-js/server

public static String toNormalizedString(Date d) {
  // TODO - improve perf here
  return new SimpleDateFormat(DEFAULT_DATE_PATTERN).format(new java.util.Date((long) d.getTime()));
}
origin: com.eduworks/org.cassproject.schema.general

/**
 * Updates the ID timestamp of the object, for versioning purposes.
 *
 * @method updateTimestamp
 */
public void updateTimestamp() {
  String rawId = id.substring(0, id.lastIndexOf("/"));
  if (rawId.endsWith("/") == false)
    rawId += "/";
  rawId += new Date().getTime();
  id = rawId;
}
origin: org.st-js/shared

/**
 * Computes the date from the given arguments interpreting them as UTC and 
 * returns the corresponding time value.
 * 
 * <p>The <tt>UTC</tt> function differs from the <tt>Date</tt> constructor 
 * in two ways: it returns a time value as a <tt>Number</tt>, rather than 
 * creating a <tt>Date</tt> object, and it interprets the arguments in UTC
 * rather than as local time.
 * 
 * @param year the year (in UTC time zone)
 * @param month the month of the year (in UTC time zone)
 * @param day the day of the month (in UTC time zone)
 * @param hours the hour of the day (in UTC time zone)
 * @param minutes the minute of the hour (in UTC time zone)
 * @param seconds the second of the minute (in UTC time zone)
 * @param ms the milliseconds of the second (in UTC time zone)
 * @return the UTC time value corresponding to the given arguments
 */
public static double UTC(int year, int month, int day, int hours, int minutes, int seconds, int ms) {
  return new Date(year, month, day, hours, minutes, seconds, ms).getTime();
}
 
origin: com.eduworks/cass.rollup

  @Override
  public void $invoke(Long expirationDate) {
    //null expiration date or expired assertion
    if (expirationDate == null || expirationDate <= (long) new Date().getTime()) {
      cgb.assertionsFilledIn++;
      cgb.checkAssertionDetailsFetched();
    } else {
      sa.setExpirationDate(expirationDate);
      cgb.fetchAssertionDetailsNegativeStatus(a, sa);
    }
  }
},
origin: org.st-js/shared

/**
 * Returns the time value designating the UTC date and time of at the 
 * moment <tt>now</tt> is called.
 * 
 * @return the time value designating the UTC date and time of at the moment <tt>now</tt> is called.
 */
@BrowserCompatibility("IE:9+")
public static double now(){
  return new Date().getTime();
}
origin: com.eduworks/cass.rollup

  @Override
  public void $invoke(Long assertionDate) {
    //null assertion date or future assertion
    if (assertionDate == null || assertionDate > (long) new Date().getTime()) {
      cgb.assertionsFilledIn++;
      cgb.checkAssertionDetailsFetched();
    } else {
      sa.setAssertionDate(assertionDate);
      cgb.fetchAssertionDetailsExpirationDate(a, sa);
    }
  }
},
origin: com.eduworks/cass.rollup

protected void log(Object string) {
  if (logFunction != null)
    logFunction.$invoke("" + new Date().getTime() % 100000 + ": " + string);
}
origin: com.eduworks/org.cassproject.schema.general

/**
 * Will generate an identifier using the server URL provided (usually from
 * an EcRepository).
 *
 * @param {string} server Base URL of the server's repository functionality.
 * @method generateId
 */
public void generateId(String server) {
  id = server;
  if (!id.endsWith("/") && !id.endsWith("ce-"))
    id += "/";
  id += "data/";
  id += getDottedType();
  id += "/";
  id += EcRandom.generateUUID();
  id += "/";
  id += new Date().getTime();
}
origin: com.eduworks/org.cassproject.schema.general

/**
 * Will generate an identifier using the server URL provided (usually from
 * an EcRepository) and unique identifier.
 *
 * @param {string} server Base URL of the server's repository functionality.
 * @param {string} uniqueIdentifier Canonical identifier. Must contain a letter or symbol.
 * @method assignId
 */
public void assignId(String server, String uniqueIdentifier) {
  id = server;
  if (!id.endsWith("/"))
    id += "/";
  id += "data/"; //endpoint to CRUD data
  id += getDottedType(); //type information (ease of use)
  id += "/";
  id += uniqueIdentifier; //local identifier
  id += "/";
  id += new Date().getTime(); //version
}
origin: org.st-js/shared

return new Date(date).getTime();
origin: com.eduworks/ebac.repository

  @Override
  public void $invoke(Object p1) {
    if (p1 != null) {
      if (JSObjectAdapter.$get(p1, "ping") == "pong") {
        if (JSObjectAdapter.$get(p1, "time") != null)
          me.timeOffset = ((Long)(Object)new Date().getTime())-((Long)(Object)JSObjectAdapter.$get(p1, "time"));
        me.selectedServer = guess;
        me.autoDetectFound = true;
      }
    }
  }
};
origin: com.eduworks/cass.rollup

private void processInputParameters(CompetencyGraph inputGraph, String subjectPem, Long predictionDate, PapDependencyDefinitions dependencyDefs, PapSettings settings) {
  this.dependencyDefs = dependencyDefs;
  verifyDependencyDefs();
  this.settings = settings;
  if (this.settings == null) this.settings = new PapSettings();
  this.inputGraph = inputGraph;
  this.subjectPem = subjectPem;
  if (this.subjectPem != null) this.subjectPem = this.subjectPem.trim();
  this.predictionDate = predictionDate;
  if (this.predictionDate == null) this.predictionDate = (long)(new Date()).getTime();
  stepSize = STEP_SIZE_NUMERATOR /this.settings.getIterations();
  priorityQueueThreshold = this.settings.getPriorityQueueThreshold()/this.settings.getIterations();
}
origin: com.eduworks/cass.rollup

public void log(InquiryPacket ip, Object string) {
  if (logFunction != null) {
    String id = "";
    if (ip.competency != null && ip.competency.$length() > 0)
      id = ip.competency.$get(0).shortId() + ":";
    logFunction.$invoke(new Date().getTime() % 100000 + ": " + string);
  }
  ip.log += "\n" + string;
}
origin: com.eduworks/ebac.repository

  @Override
  public void $invoke(Object p1) {
    if (p1 != null) {
      if (JSObjectAdapter.$get(p1, "ping") == "pong") {
        if (JSObjectAdapter.$get(p1, "time") != null)
          me.timeOffset = ((Long)(Object)new Date().getTime())-((Long)(Object)JSObjectAdapter.$get(p1, "time"));
        if (me.autoDetectFound == false) {
          me.selectedServer = guess;
          me.autoDetectFound = true;
          success.$invoke();
        }
      }
    }
  }
};
origin: com.eduworks/ebac.identity

  @Override
  public void $invoke(Array<EcIdentity> pks) {
    Array cache = null;
    String stringified = JSGlobal.JSON.stringify(signatures);
    if (signatureSheetCaching) {
      cache = new Array();
      cache.$set(0, new Date().getTime() + finalDuration);
      cache.$set(1, stringified);
      JSObjectAdapter.$put(signatureSheetCache, server, cache);
    }
    success.$invoke(stringified);
  }
});
origin: com.eduworks/ebac.identity

/**
 * Asynchronously create a signature for a specific identity
 *
 * @param {long}   duration Length of time in milliseconds to authorize
 *                 control.
 * @param {String} server Server that we are authorizing.
 * @param {EcPpk}  ppk Key of the identity to create a signature for
 * @param success  Callback triggered once the signature sheet has been
 *                 created, returns the signature
 * @memberOf EcIdentityManager
 * @method createSignatureAsync
 * @static
 */
private static void createSignatureAsync(long duration, String server, EcPpk ppk, final Callback1<EbacSignature> success, final Callback1<String> failure) {
  final EbacSignature s = new EbacSignature();
  s.owner = ppk.toPk().toPem();
  s.expiry = new Date().getTime() + duration;
  s.server = server;
  EcRsaOaepAsync.sign(ppk, s.toJson(), new Callback1<String>() {
    @Override
    public void $invoke(String p1) {
      s.signature = p1;
      success.$invoke(s);
    }
  }, failure);
}
origin: com.eduworks/ebac.identity

/**
 * Create a signature for a specific identity, authorizing movement of data
 * outside of our control.
 *
 * @param {long}   duration Length of time in milliseconds to authorize
 *                 control.
 * @param {String} server Server that we are authorizing.
 * @param {EcPpk}  ppk Key of the identity to create a signature for
 * @return {Ebac Signature} Signature created
 * @memberOf EcIdentityManager
 * @method createSignature
 * @static
 */
public static EbacSignature createSignature(long duration, String server, EcPpk ppk) {
  EbacSignature s = new EbacSignature();
  s.owner = ppk.toPk().toPem();
  s.expiry = new Date().getTime() + duration;
  s.server = server;
  s.signature = EcRsaOaep.sign(ppk, s.toJson());
  return s;
}
origin: com.eduworks/ebac.identity

  cache = (Array) JSObjectAdapter.$get(signatureSheetCache, server);
  if (cache != null) {
    if ((Long) cache.$get(0) > new Date().getTime() + duration) {
      return (String) cache.$get(1);
if (signatureSheetCaching) {
  cache = new Array();
  cache.$set(0, new Date().getTime() + duration);
  cache.$set(1, stringified);
  JSObjectAdapter.$put(signatureSheetCache, server, cache);
origin: com.eduworks/cass.rollup

equivalentPackets = new Array<InquiryPacket>();
subPackets = new Array<InquiryPacket>();
dateCreated = new Date().getTime();
this.subject = subject;
this.competency = new Array<>();
org.stjs.javascriptDategetTime

Javadoc

Returns the time value associated to this Date

Popular methods of Date

  • <init>
    Constructs a new Date object by parsing its string representation, and setting it's value to the res
  • UTC
    Computes the date from the given arguments interpreting them as UTC and returns the corresponding ti
  • getCalendar
  • getDate
    Returns the day of the month corresponding to this Date's time value, in the local time zone.
  • getDay
    Returns the day of the week corresponding to this Date's time value, in the local time zone. A weekd
  • getField
  • getFullYear
    Returns the year corresponding to this Date's time value, in the local time zone.
  • getMilliseconds
    Returns the milliseconds of the second corresponding to this Date's time value, in the local time zo
  • getMinutes
    Returns the minutes of the hour corresponding to this Date's time value, in the local time zone.
  • getMonth
    Returns the month number corresponding to this Date's time value, in the local time zone. Month numb
  • getSeconds
    Returns the seconds of the minute corresponding to this Date's time value, in the local time zone.
  • getUTC
  • getSeconds,
  • getUTC,
  • getUTCDate,
  • getUTCDay,
  • getUTCMilliseconds,
  • getUTCMinutes,
  • getUTCMonth,
  • getUTCSeconds,
  • setDate

Popular in Java

  • Updating database using SQL prepared statement
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • notifyDataSetChanged (ArrayAdapter)
  • setScale (BigDecimal)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • String (java.lang)
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now