Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // must be in this package to have access to `nestedScrollingChildRef` | |
| package com.google.android.material.bottomsheet | |
| import android.content.Context | |
| import android.util.AttributeSet | |
| import android.view.View | |
| import androidx.coordinatorlayout.widget.CoordinatorLayout | |
| import java.lang.ref.WeakReference | |
| class ViewPagerBottomSheetBehavior<V : View>(context: Context, attrs: AttributeSet?) : BottomSheetBehavior<V>(context, attrs) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| V/REALM_JNI: --> finalize_unchecked_row -786967184 | |
| V/REALM_JNI: --> Java_io_realm_internal_UncheckedRow_nativeGetString -870263440 | |
| V/REALM_JNI: --> Java_io_realm_internal_OsSharedRealm_nativeIsClosed -339864272 | |
| --> Java_io_realm_internal_UncheckedRow_nativeGetString -870263440 | |
| --> Java_io_realm_internal_OsSharedRealm_nativeIsClosed -339864272 | |
| --> Java_io_realm_internal_UncheckedRow_nativeGetString -870263440 | |
| --> Java_io_realm_internal_OsSharedRealm_nativeIsClosed -339864272 | |
| --> Java_io_realm_internal_OsList_nativeCreate -870263440 | |
| --> Java_io_realm_internal_OsSharedRealm_nativeIsClosed -339864272 | |
| --> Java_io_realm_internal_OsSharedRealm_nativeIsClosed -339864272 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* 1 */ | |
| { | |
| "_id" : ObjectId("57eaf642ff01db2659e2af49"), | |
| "value" : { | |
| "country" : "US", | |
| "gender" : "F", | |
| "age" : "13" | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var crypto = require('crypto'); | |
| var md5 = crypto.createHash('md5'); | |
| var request = require('request'); | |
| var api_key = 'your_api_key_here'; | |
| var api_secret = 'your_api_secret_here'; | |
| var api_endpoint = 'https://data.mixpanel.com/api/2.0/'; | |
| var current_time = parseInt((new Date().getTime())/1000); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var timestampMoment = moment.unix(res.body.timestamp); | |
| (timestampMoment.isBetween(before.subtract(1, 'second'), moment().add(1, 'second'))).should.be.true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var hat = require('hat'); | |
| var _ = require('lodash'); | |
| var rack = {}; | |
| for(var i = 0; i < 1000000; i++) { | |
| var id = hat(); | |
| rack[id] = rack[id] ? rack[id] + 1 : 1; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| getDayName = function(day) | |
| { | |
| return {0:"Sunday",1:"Monday",2:"Tuesday",3:"Wednesday",4:"Thursday",5:"Friday",6:"Saturday"}[day]; | |
| }; | |
| getDayDiffString = function(now, before) | |
| { | |
| if((now - before) < 1000*60*60*24*5) | |
| { | |
| var dayDiff = now.getDay() - before.getDay(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #example data | |
| data = [ | |
| { | |
| :time => Time.now - 2.days, | |
| :value => 2321.65 | |
| }, | |
| { | |
| :time => Time.now - 1.days, | |
| :value => 1307.98 | |
| }, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function JSON2CSV(objArray) { | |
| var array = typeof objArray != 'object' ? JSON.parse(objArray) : objArray; | |
| var str = ''; | |
| var line = ''; | |
| if ($("#labels").is(':checked')) { | |
| var head = array[0]; | |
| if ($("#quote").is(':checked')) { | |
| for (var index in array[0]) { |
NewerOlder