blob_id
stringlengths 40
40
| directory_id
stringlengths 40
40
| path
stringlengths 7
390
| content_id
stringlengths 40
40
| detected_licenses
listlengths 0
35
| license_type
stringclasses 2
values | repo_name
stringlengths 6
132
| snapshot_id
stringlengths 40
40
| revision_id
stringlengths 40
40
| branch_name
stringclasses 539
values | visit_date
timestamp[us]date 2016-08-02 21:09:20
2023-09-06 10:10:07
| revision_date
timestamp[us]date 1990-01-30 01:55:47
2023-09-05 21:45:37
| committer_date
timestamp[us]date 2003-07-12 18:48:29
2023-09-05 21:45:37
| github_id
int64 7.28k
684M
⌀ | star_events_count
int64 0
77.7k
| fork_events_count
int64 0
48k
| gha_license_id
stringclasses 13
values | gha_event_created_at
timestamp[us]date 2012-06-11 04:05:37
2023-09-14 21:59:18
⌀ | gha_created_at
timestamp[us]date 2008-05-22 07:58:19
2023-08-28 02:39:21
⌀ | gha_language
stringclasses 62
values | src_encoding
stringclasses 26
values | language
stringclasses 1
value | is_vendor
bool 1
class | is_generated
bool 2
classes | length_bytes
int64 128
12.8k
| extension
stringclasses 11
values | content
stringlengths 128
8.19k
| authors
listlengths 1
1
| author_id
stringlengths 1
79
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
72d2d80d900bf356617b449cacb1883e8611889b
|
591184fe8b21134c30b47fa86d5a275edd3a6208
|
/openejb2/modules/openejb-core/src/main/java/org/openejb/corba/security/SASNoContextException.java
|
dfcd03dfb5999230226e796c01d5e8456ecd26fe
|
[] |
no_license
|
codehaus/openejb
|
41649552c6976bf7d2e1c2fe4bb8a3c2b82f4dcb
|
c4cd8d75133345a23d5a13b9dda9cb4b43efc251
|
refs/heads/master
| 2023-09-01T00:17:38.431680
| 2006-09-14T07:14:22
| 2006-09-14T07:14:22
| 36,228,436
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,289
|
java
|
/**
* Redistribution and use of this software and associated documentation
* ("Software"), with or without modification, are permitted provided
* that the following conditions are met:
*
* 1. Redistributions of source code must retain copyright
* statements and notices. Redistributions must also contain a
* copy of this document.
*
* 2. Redistributions in binary form must reproduce the
* above copyright notice, this list of conditions and the
* following disclaimer in the documentation and/or other
* materials provided with the distribution.
*
* 3. The name "OpenEJB" must not be used to endorse or promote
* products derived from this Software without prior written
* permission of The OpenEJB Group. For written permission,
* please contact openejb-group@openejb.sf.net.
*
* 4. Products derived from this Software may not be called "OpenEJB"
* nor may "OpenEJB" appear in their names without prior written
* permission of The OpenEJB Group. OpenEJB is a registered
* trademark of The OpenEJB Group.
*
* 5. Due credit should be given to the OpenEJB Project
* (http://openejb.sf.net/).
*
* THIS SOFTWARE IS PROVIDED BY THE OPENEJB GROUP AND CONTRIBUTORS
* ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT
* NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
* THE OPENEJB GROUP OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
* OF THE POSSIBILITY OF SUCH DAMAGE.
*
* Copyright 2005 (C) The OpenEJB Group. All Rights Reserved.
*
* $Id$
*/
package org.openejb.corba.security;
import org.omg.CORBA.NO_PERMISSION;
/**
* @version $Revision$ $Date$
*/
public class SASNoContextException extends SASException {
public SASNoContextException() {
super(4, new NO_PERMISSION());
}
}
|
[
"dain@2b0c1533-c60b-0410-b8bd-89f67432e5c6"
] |
dain@2b0c1533-c60b-0410-b8bd-89f67432e5c6
|
50c4bd7a669ab82deb33fd65b4e7436f07f7019b
|
6b83984ff783452c3e9aa2b7a1d16192b351a60a
|
/question0972_equal_rational_numbers/Solution.java
|
6b8126575da75e7e6890dbc8f7f6751f9fb0d13b
|
[] |
no_license
|
617076674/LeetCode
|
aeedf17d7cd87b9e59e0a107cd6af5ce9bac64f8
|
0718538ddb79e71fec9a330ea27524a60eb60259
|
refs/heads/master
| 2022-05-13T18:29:44.982447
| 2022-04-13T01:03:28
| 2022-04-13T01:03:28
| 146,989,451
| 207
| 58
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,485
|
java
|
package question0972_equal_rational_numbers;
public class Solution {
private static class Fraction {
long n, d;
Fraction(long n, long d) {
long g = gcd(n, d);
this.n = n / g;
this.d = d / g;
}
public void iadd(Fraction other) {
long numerator = this.n * other.d + this.d * other.n;
long denominator = this.d * other.d;
long g = Fraction.gcd(numerator, denominator);
this.n = numerator / g;
this.d = denominator / g;
}
static long gcd(long x, long y) {
return x != 0 ? gcd(y % x, x) : y;
}
}
public boolean isRationalEqual(String S, String T) {
Fraction f1 = convert(S);
Fraction f2 = convert(T);
return f1.n == f2.n && f1.d == f2.d;
}
public Fraction convert(String S) {
int state = 0; //whole, decimal, repeating
Fraction ans = new Fraction(0, 1);
int decimal_size = 0;
for (String part : S.split("[.()]")) {
state++;
if (part.isEmpty()) {
continue;
}
long x = Long.parseLong(part);
int sz = part.length();
if (state == 1) { // whole
ans.iadd(new Fraction(x, 1));
} else if (state == 2) { // decimal
ans.iadd(new Fraction(x, (long) Math.pow(10, sz)));
decimal_size = sz;
} else { // repeating
long denom = (long) Math.pow(10, decimal_size);
denom *= (long) (Math.pow(10, sz) - 1);
ans.iadd(new Fraction(x, denom));
}
}
return ans;
}
}
|
[
"zhuchen@pinduoduo.com"
] |
zhuchen@pinduoduo.com
|
0711458e3c276a88b2ea4a630f402ba15a06a020
|
a9843bd3a8c4a0d2eb720746d83ce6a609802f35
|
/java/bypstest-ser-json/src/byps/test/api/srvr/JSerializer_7007.java
|
3ed066beac99e53d61143bfb5afc6431e4de9b74
|
[
"MIT"
] |
permissive
|
digideskio/byps
|
0d99da7cc488d5cbbe9d46b77ce1ac5e808be8da
|
5f3933faacad255ae8f1fb11585ee681ad4444a9
|
refs/heads/master
| 2021-01-18T01:31:09.543537
| 2016-05-16T09:13:31
| 2016-05-16T09:21:05
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,331
|
java
|
package byps.test.api.srvr;
/*
* Serializer for byps.test.api.srvr.ChatStructure
*
* THIS FILE HAS BEEN GENERATED BY class byps.gen.j.GenSerStructJson DO NOT MODIFY.
*/
import byps.*;
// DEBUG
// isEnum=false
// isFinal=false
// isInline=false
// #members=3
// checkpoint byps.gen.j.GenSerStruct:274
@SuppressWarnings("all")
public class JSerializer_7007 extends JSerializer_Object {
public final static BSerializer instance = new JSerializer_7007();
public JSerializer_7007() {
super(7007);
}
public JSerializer_7007(int typeId) {
super(typeId);
}
@Override
public void internalWrite(final Object obj1, final BOutputJson bout, final BBufferJson bbuf) throws BException {
final ChatStructure obj = (ChatStructure)obj1;
bbuf.putString("msg", obj.msg);
bbuf.putDouble("receivedAt", obj.receivedAt);
bbuf.putDouble("sentAt", obj.sentAt);
}
@Override
public Object internalRead(final Object obj1, final BInputJson bin) throws BException {
final ChatStructure obj = (ChatStructure)(obj1 != null ? obj1 : bin.onObjectCreated(new ChatStructure()));
final BJsonObject js = bin.currentObject;
obj.msg = js.getString("msg");
obj.receivedAt = js.getDouble("receivedAt");
obj.sentAt = js.getDouble("sentAt");
return obj;
}
}
|
[
"wolfgang.imig@googlemail.com"
] |
wolfgang.imig@googlemail.com
|
01173c67d2836834aeb0cb055c4fab7f9fdf75f4
|
eec7bf6b543dd8b961d8bd08b506e8bb38d949ab
|
/src/main/java/net/sf/ehcache/util/MemoryEfficientByteArrayOutputStream.java
|
2d6c5449b3777f911cf8f2491a90558d8d70de51
|
[] |
no_license
|
ystory/ehcache-core-2.6.11
|
70de1feff3c321898937ee70df30dc9ce39c228c
|
3d7440fe1478450b16d3ccb8ed20b303659140ce
|
refs/heads/master
| 2022-07-25T17:34:51.803015
| 2015-03-06T15:28:38
| 2015-03-06T15:28:38
| 39,236,553
| 4
| 3
| null | 2022-06-29T19:26:06
| 2015-07-17T05:29:08
|
Java
|
UTF-8
|
Java
| false
| false
| 3,723
|
java
|
/**
* Copyright Terracotta, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package net.sf.ehcache.util;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.ObjectOutputStream;
import java.io.Serializable;
/**
* This class is designed to minimise the number of System.arraycopy(); methods
* required to complete.
*
* ByteArrayOutputStream in the JDK is tuned for a wide variety of purposes. This sub-class
* starts with an initial size which is a closer match for ehcache usage.
*
* @author <a href="mailto:gluck@gregluck.com">Greg Luck</a>
* @version $Id$
*/
public final class MemoryEfficientByteArrayOutputStream extends ByteArrayOutputStream {
/**
* byte[] payloads are not expected to be tiny.
*/
private static final int BEST_GUESS_SIZE = 512;
private static int lastSize = BEST_GUESS_SIZE;
/**
* Creates a new byte array output stream, with a buffer capacity of
* the specified size, in bytes.
*
* @param size the initial size.
*/
public MemoryEfficientByteArrayOutputStream(int size) {
super(size);
}
/**
* Gets the bytes.
*
* @return the underlying byte[], or a copy if the byte[] is oversized
*/
public synchronized byte getBytes()[] {
if (buf.length == size()) {
return buf;
} else {
byte[] copy = new byte[size()];
System.arraycopy(buf, 0, copy, 0, size());
return copy;
}
}
/**
* Factory method
* @param serializable any Object that implements Serializable
* @param estimatedPayloadSize how many bytes is expected to be in the Serialized representation
* @return a ByteArrayOutputStream with a Serialized object in it
* @throws java.io.IOException if something goes wrong with the Serialization
*/
public static MemoryEfficientByteArrayOutputStream serialize(Serializable serializable, int estimatedPayloadSize) throws IOException {
MemoryEfficientByteArrayOutputStream outstr = new MemoryEfficientByteArrayOutputStream(estimatedPayloadSize);
ObjectOutputStream objstr = new ObjectOutputStream(outstr);
objstr.writeObject(serializable);
objstr.close();
return outstr;
}
/**
* Factory method. This method optimises memory by trying to make a better guess than the Java default
* of 32 bytes by assuming the starting point for the serialized size will be what it was last time
* this method was called.
* @param serializable any Object that implements Serializable
* @return a ByteArrayOutputStream with a Serialized object in it
* @throws java.io.IOException if something goes wrong with the Serialization
*/
public static MemoryEfficientByteArrayOutputStream serialize(Serializable serializable) throws IOException {
MemoryEfficientByteArrayOutputStream outstr = new MemoryEfficientByteArrayOutputStream(lastSize);
ObjectOutputStream objstr = new ObjectOutputStream(outstr);
objstr.writeObject(serializable);
objstr.close();
lastSize = outstr.getBytes().length;
return outstr;
}
}
|
[
"cruise@b9324663-ca0f-0410-8574-be9b3887307d"
] |
cruise@b9324663-ca0f-0410-8574-be9b3887307d
|
ae2a573d95d2b77bd04ec9cac9495ea16a078a0d
|
082e26b011e30dc62a62fae95f375e4f87d9e99c
|
/docs/weixin_7.0.4_source/反编译源码/反混淆后/src/main/java/com/tencent/p177mm/boot/svg/p708a/p709a/amg.java
|
30075a8e92ef98a72c2adf6d5958a62dba973554
|
[] |
no_license
|
xsren/AndroidReverseNotes
|
9631a5aabc031006e795a112b7ac756a8edd4385
|
9202c276fe9f04a978e4e08b08e42645d97ca94b
|
refs/heads/master
| 2021-04-07T22:50:51.072197
| 2019-07-16T02:24:43
| 2019-07-16T02:24:43
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 7,002
|
java
|
package com.tencent.p177mm.boot.svg.p708a.p709a;
import android.graphics.Canvas;
import android.graphics.Matrix;
import android.graphics.Paint;
import android.graphics.Paint.Cap;
import android.graphics.Paint.Join;
import android.graphics.Paint.Style;
import android.graphics.Path;
import android.os.Looper;
import com.tencent.p177mm.svg.C5163c;
import com.tencent.p177mm.svg.WeChatSVGRenderC2Java;
import com.tencent.smtt.sdk.WebView;
/* renamed from: com.tencent.mm.boot.svg.a.a.amg */
public final class amg extends C5163c {
private final int height = 52;
private final int width = 48;
/* renamed from: a */
public final int mo10620a(int i, Object... objArr) {
switch (i) {
case 0:
return 48;
case 1:
return 52;
case 2:
Canvas canvas = (Canvas) objArr[0];
Looper looper = (Looper) objArr[1];
Matrix h = C5163c.m7881h(looper);
float[] g = C5163c.m7880g(looper);
Paint k = C5163c.m7883k(looper);
k.setFlags(385);
k.setStyle(Style.FILL);
Paint k2 = C5163c.m7883k(looper);
k2.setFlags(385);
k2.setStyle(Style.STROKE);
k.setColor(WebView.NIGHT_MODE_COLOR);
k2.setStrokeWidth(1.0f);
k2.setStrokeCap(Cap.BUTT);
k2.setStrokeJoin(Join.MITER);
k2.setStrokeMiter(4.0f);
k2.setPathEffect(null);
C5163c.m7876a(k2, looper).setStrokeWidth(1.0f);
canvas.save();
Paint a = C5163c.m7876a(k, looper);
a.setColor(-1);
g = C5163c.m7878a(g, 1.0f, 0.0f, -8.0f, 0.0f, 1.0f, -6.0f);
h.reset();
h.setValues(g);
canvas.concat(h);
canvas.save();
Paint a2 = C5163c.m7876a(a, looper);
Path l = C5163c.m7884l(looper);
l.moveTo(24.80435f, 38.659184f);
l.cubicTo(24.637218f, 38.487045f, 24.6045f, 38.174816f, 24.726532f, 37.968803f);
l.lineTo(25.386211f, 36.854485f);
l.cubicTo(25.510012f, 36.644806f, 25.781488f, 36.56881f, 25.990181f, 36.682346f);
l.lineTo(30.773296f, 39.283638f);
l.cubicTo(31.195103f, 39.513462f, 31.854782f, 39.464016f, 32.22972f, 39.1875f);
l.lineTo(45.16686f, 29.642105f);
l.cubicTo(45.357864f, 29.501099f, 45.648796f, 29.51758f, 45.827423f, 29.688803f);
l.lineTo(46.070602f, 29.922287f);
l.cubicTo(46.24481f, 30.08893f, 46.248344f, 30.366365f, 46.0821f, 30.538502f);
l.lineTo(32.136868f, 44.987984f);
l.cubicTo(31.805262f, 45.331345f, 31.269382f, 45.33409f, 30.92451f, 44.977913f);
l.lineTo(24.80435f, 38.659184f);
l.close();
l.moveTo(12.888889f, 32.348488f);
l.cubicTo(12.644444f, 32.348488f, 12.444445f, 32.550213f, 12.444445f, 32.796764f);
l.lineTo(12.444445f, 52.988007f);
l.cubicTo(12.444445f, 53.237247f, 12.636444f, 53.43449f, 12.881778f, 53.436283f);
l.cubicTo(19.092443f, 53.477524f, 37.99289f, 53.602146f, 40.093334f, 53.425526f);
l.cubicTo(42.373333f, 53.23366f, 45.365334f, 52.000904f, 46.518223f, 51.02725f);
l.cubicTo(52.352f, 46.09711f, 51.52178f, 32.061592f, 50.393776f, 29.480421f);
l.cubicTo(49.748444f, 28.0038f, 46.894222f, 27.45511f, 45.588444f, 27.417456f);
l.cubicTo(45.08889f, 27.41656f, 43.112f, 27.308973f, 41.523556f, 25.757938f);
l.cubicTo(40.651554f, 24.90711f, 39.612446f, 23.31842f, 39.612446f, 20.58125f);
l.cubicTo(39.612446f, 16.276007f, 39.393776f, 13.897455f, 38.152f, 12.019179f);
l.cubicTo(37.90489f, 11.644421f, 36.045334f, 10.231455f, 34.06222f, 11.176421f);
l.cubicTo(33.340443f, 11.520697f, 33.217777f, 12.341938f, 33.112f, 15.418903f);
l.cubicTo(33.096f, 15.881524f, 33.079113f, 16.366558f, 33.05511f, 16.874903f);
l.cubicTo(32.905777f, 20.137455f, 32.761776f, 21.871386f, 32.098667f, 23.672558f);
l.cubicTo(31.076445f, 26.449179f, 29.518223f, 28.351662f, 27.046223f, 29.838144f);
l.cubicTo(25.94489f, 30.4998f, 24.438223f, 31.40711f, 22.61511f, 31.817732f);
l.cubicTo(20.514668f, 32.292904f, 18.948444f, 32.348488f, 17.953777f, 32.348488f);
l.lineTo(12.888889f, 32.348488f);
l.close();
l.moveTo(31.533333f, 57.99973f);
l.cubicTo(26.16711f, 57.99973f, 19.216888f, 57.96028f, 12.852445f, 57.91904f);
l.cubicTo(10.176888f, 57.90111f, 8.0f, 55.68842f, 8.0f, 52.988007f);
l.lineTo(8.0f, 32.796764f);
l.cubicTo(8.0f, 30.07842f, 10.193778f, 27.86573f, 12.888889f, 27.86573f);
l.lineTo(17.953777f, 27.86573f);
l.cubicTo(18.803556f, 27.86573f, 19.990223f, 27.817318f, 21.644444f, 27.443455f);
l.cubicTo(22.773333f, 27.188835f, 23.88f, 26.523594f, 24.769777f, 25.987455f);
l.cubicTo(26.107555f, 25.183249f, 27.158222f, 24.21587f, 27.932444f, 22.111662f);
l.cubicTo(28.355556f, 20.963179f, 28.473778f, 19.74387f, 28.616f, 16.666903f);
l.cubicTo(28.63911f, 16.176489f, 28.654222f, 15.708489f, 28.670221f, 15.2638f);
l.cubicTo(28.786667f, 11.879317f, 28.896f, 8.682214f, 32.161777f, 7.1240067f);
l.lineTo(32.162666f, 7.1240067f);
l.cubicTo(36.176888f, 5.2089725f, 40.366222f, 7.2907653f, 41.84889f, 9.531248f);
l.cubicTo(43.716446f, 12.353593f, 44.05689f, 15.466421f, 44.05689f, 20.58125f);
l.cubicTo(44.05689f, 21.225868f, 44.153778f, 22.087456f, 44.614223f, 22.537523f);
l.cubicTo(44.981335f, 22.894352f, 45.532444f, 22.935593f, 45.538666f, 22.935593f);
l.lineTo(45.539555f, 22.935593f);
l.lineTo(45.595554f, 22.9338f);
l.lineTo(45.651554f, 22.934696f);
l.cubicTo(46.34667f, 22.948145f, 52.499557f, 23.185732f, 54.460445f, 27.671179f);
l.cubicTo(56.191113f, 31.631248f, 57.154667f, 47.886627f, 49.372444f, 54.462833f);
l.cubicTo(47.397335f, 56.132214f, 43.484444f, 57.63842f, 40.46311f, 57.892143f);
l.cubicTo(39.526222f, 57.971043f, 36.10311f, 57.99973f, 31.533333f, 57.99973f);
l.lineTo(31.533333f, 57.99973f);
l.close();
WeChatSVGRenderC2Java.setFillType(l, 2);
canvas.drawPath(l, a2);
canvas.restore();
canvas.restore();
C5163c.m7882j(looper);
break;
}
return 0;
}
}
|
[
"alwangsisi@163.com"
] |
alwangsisi@163.com
|
1d25599234b154cbc93dc77a2f99939c6ea4c47e
|
222c56bda708da134203560d979fb90ba1a9da8d
|
/uapunit测试框架/engine/src/public/uap/workflow/engine/query/HistoricDetailQueryProperty.java
|
ba3341b7d6588677c53ed468ee0f89e9a3e63289
|
[] |
no_license
|
langpf1/uapunit
|
7575b8a1da2ebed098d67a013c7342599ef10ced
|
c7f616bede32bdc1c667ea0744825e5b8b6a69da
|
refs/heads/master
| 2020-04-15T00:51:38.937211
| 2013-09-13T04:58:27
| 2013-09-13T04:58:27
| 12,448,060
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,943
|
java
|
/* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package uap.workflow.engine.query;
import java.util.HashMap;
import java.util.Map;
import uap.workflow.engine.history.HistoricDetailQuery;
/**
* Contains the possible properties which can be used in a {@link HistoricDetailQuery}.
*
* @author Tom Baeyens
*/
public class HistoricDetailQueryProperty implements QueryProperty {
private static final long serialVersionUID = 1L;
private static final Map<String, HistoricDetailQueryProperty> properties = new HashMap<String, HistoricDetailQueryProperty>();
public static final HistoricDetailQueryProperty PROCESS_INSTANCE_ID = new HistoricDetailQueryProperty("PROC_INST_ID_");
public static final HistoricDetailQueryProperty VARIABLE_NAME = new HistoricDetailQueryProperty("NAME_");
public static final HistoricDetailQueryProperty VARIABLE_TYPE = new HistoricDetailQueryProperty("TYPE_");
public static final HistoricDetailQueryProperty VARIABLE_REVISION = new HistoricDetailQueryProperty("REV_");
public static final HistoricDetailQueryProperty TIME = new HistoricDetailQueryProperty("TIME_");
private String name;
public HistoricDetailQueryProperty(String name) {
this.name = name;
properties.put(name, this);
}
public String getName() {
return name;
}
public static HistoricDetailQueryProperty findByName(String propertyName) {
return properties.get(propertyName);
}
}
|
[
"langpf1@yonyou.com"
] |
langpf1@yonyou.com
|
5a17e53cd9a2629959063fd22d15c821c4bcad45
|
8c39b7d1c81514177f92194b8fb453eb61ab4762
|
/src/thothbot/parallax/demo/client/content/misc/MiscMemoryTestGeometries.java
|
3f4cbdc2c76793f1f84ad504ae6359949837e339
|
[
"CC-BY-3.0"
] |
permissive
|
svv2014/parallax-demo
|
de32997f54f81e66bb92344bf9f495c6a453fae8
|
0cee716898fda0051e6927b431373108c1d32332
|
refs/heads/master
| 2020-12-25T06:03:06.387932
| 2015-03-01T22:13:30
| 2015-03-01T22:13:30
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,578
|
java
|
/*
* Copyright 2012 Alex Usachev, thothbot@gmail.com
*
* This file is part of Parallax project.
*
* Parallax is free software: you can redistribute it and/or modify it
* under the terms of the Creative Commons Attribution 3.0 Unported License.
*
* Parallax is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the Creative Commons Attribution
* 3.0 Unported License. for more details.
*
* You should have received a copy of the the Creative Commons Attribution
* 3.0 Unported License along with Parallax.
* If not, see http://creativecommons.org/licenses/by/3.0/.
*/
package thothbot.parallax.demo.client.content.misc;
import thothbot.parallax.core.client.textures.Texture;
import thothbot.parallax.core.shared.cameras.PerspectiveCamera;
import thothbot.parallax.core.shared.geometries.SphereGeometry;
import thothbot.parallax.core.shared.materials.MeshBasicMaterial;
import thothbot.parallax.core.shared.objects.Mesh;
import thothbot.parallax.demo.client.ContentWidget;
import thothbot.parallax.demo.client.DemoAnnotations.DemoSource;
import com.google.gwt.canvas.dom.client.Context2d;
import com.google.gwt.core.client.GWT;
import com.google.gwt.core.client.RunAsyncCallback;
import com.google.gwt.dom.client.CanvasElement;
import com.google.gwt.dom.client.Document;
import com.google.gwt.user.client.rpc.AsyncCallback;
public final class MiscMemoryTestGeometries extends ContentWidget
{
/*
* Prepare Rendering Scene
*/
@DemoSource
class DemoScene extends DemoAnimatedScene
{
PerspectiveCamera camera;
Mesh mesh;
Texture texture;
@Override
protected void onStart()
{
camera = new PerspectiveCamera(
60, // fov
getRenderer().getAbsoluteAspectRation(), // aspect
1, // near
10000 // far
);
camera.getPosition().setZ(200);
}
@Override
protected void onUpdate(double duration)
{
SphereGeometry geometry = new SphereGeometry( 50, (int)(Math.random() * 64), (int)(Math.random() * 32) );
texture = new Texture( generateTexture() );
texture.setNeedsUpdate(true);
MeshBasicMaterial material = new MeshBasicMaterial();
material.setMap(texture);
material.setWireframe(true);
mesh = new Mesh( geometry, material );
getScene().add( mesh );
getRenderer().render(getScene(), camera);
getScene().remove( mesh );
// clean up
geometry.dispose();
// material.dispose();
// texture.dispose();
}
private CanvasElement generateTexture()
{
CanvasElement canvas = Document.get().createElement("canvas").cast();
canvas.setWidth(256);
canvas.setHeight(256);
Context2d context = canvas.getContext2d();
context.setFillStyle("rgb(" + Math.floor( Math.random() * 256 )
+ "," + Math.floor( Math.random() * 256 )
+ "," + Math.floor( Math.random() * 256 ) + ")");
context.fillRect( 0, 0, 256, 256 );
return canvas;
}
}
public MiscMemoryTestGeometries()
{
super("Memory test: geometries", "This example based on the three.js example.");
}
@Override
public DemoScene onInitialize()
{
return new DemoScene();
}
@Override
protected void asyncOnInitialize(final AsyncCallback<DemoAnimatedScene> callback)
{
GWT.runAsync(MiscMemoryTestGeometries.class, new RunAsyncCallback()
{
public void onFailure(Throwable caught)
{
callback.onFailure(caught);
}
public void onSuccess()
{
callback.onSuccess(onInitialize());
}
});
}
}
|
[
"thothbot@gmail.com"
] |
thothbot@gmail.com
|
fa8ebd2519f6a43ae0610638f2f8f79ce09936a9
|
dfc523f19f6f26cd30b94f83cd9945a9670de518
|
/数据结构/src/AVL树/Main.java
|
254ec97e9080f9838f069c1a28a8f56051e7a626
|
[] |
no_license
|
DoubleEar/javapractice
|
0251cee7bb193427cbbb485768f2009249ca1d2d
|
0cff08e52ac51c1993f85484a82f106220e0dc90
|
refs/heads/master
| 2022-06-28T21:29:06.495901
| 2020-09-20T15:25:45
| 2020-09-20T15:25:45
| 217,519,133
| 0
| 0
| null | 2022-06-21T03:38:43
| 2019-10-25T11:28:54
|
Java
|
UTF-8
|
Java
| false
| false
| 504
|
java
|
package AVL树;
//验证AVL树的正确性
import java.util.Random;
public class Main {
public static void main(String[] args) {
Random random = new Random(20200705);
AVLTree tree = new AVLTree();
for (int i = 0; i < 1000; i++) {
int r = random.nextInt(10000);
try {
tree.insert(r);
} catch (RuntimeException e) {
System.out.println(e.getMessage());
}
}
tree.verify();
}
}
|
[
"1638435068@qq.com"
] |
1638435068@qq.com
|
ea711a3bc342b7ef2a2df0cc55b4ddc397632a30
|
de2ea79f2d2d29bf0418ff1b4e3a6762c0576252
|
/.svn/pristine/1a/1aa978f46ffad0fb3c5ec7b580f671136fbeb450.svn-base
|
da1e5229510ccac6c66d5a353ace0b4da896fa51
|
[] |
no_license
|
shenkuen88/MallOnlineApp
|
031dc18a7798e7f22760981de3289fbc38b0816f
|
65314dc5988cd5acf7fbdf2fcb69a78c8a5d1abf
|
refs/heads/master
| 2020-07-10T23:19:47.694326
| 2016-09-05T09:45:04
| 2016-09-05T09:45:04
| 67,347,455
| 1
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,588
|
//package com.nannong.live.main.view;
//
//
//import android.content.Context;
//import android.content.Intent;
//import android.util.AttributeSet;
//import android.view.LayoutInflater;
//import android.view.View;
//import android.view.animation.AnimationUtils;
//import android.widget.LinearLayout;
//import android.widget.RelativeLayout;
//import android.widget.TextView;
//import android.widget.ViewFlipper;
//
//import java.util.List;
//
//import cn.nj.www.my_module.R;
//import cn.nj.www.my_module.bean.index.NoticeListBean;
//import cn.nj.www.my_module.constant.IntentCode;
//import cn.nj.www.my_module.main.base.CommonWebViewActivity;
//import cn.nj.www.my_module.tools.ToastUtil;
//
//public class PublicNoticeView extends LinearLayout {
//
// private static final String TAG = "PUBLICNOTICEVIEW";
// private Context mContext;
// private ViewFlipper mViewFlipper;
// private View mScrollTitleView;
//
// public PublicNoticeView(Context context) {
// super(context);
// mContext = context;
// init();
// }
//
// public PublicNoticeView(Context context, AttributeSet attrs) {
// super(context, attrs);
// mContext = context;
// init();
// }
//
// private void init() {
// bindLinearLayout();
// }
//
// /**
// * 初始化自定义的布局
// */
// private void bindLinearLayout() {
// mScrollTitleView = LayoutInflater.from(mContext).inflate(R.layout.scrollnoticebar, null);
// LayoutParams params = new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT);
// addView(mScrollTitleView, params);
// mViewFlipper = (ViewFlipper) mScrollTitleView.findViewById(R.id.id_scrollNoticeTitle);
// mViewFlipper.setInAnimation(AnimationUtils.loadAnimation(mContext, R.anim.slide_in_bottom));
// mViewFlipper.setOutAnimation(AnimationUtils.loadAnimation(mContext, R.anim.slide_out_top));
// mViewFlipper.startFlipping();
// }
//
// /**
// * 网络请求内容后进行适配
// */
// public void bindNotices(final List<NoticeListBean> noticeList) {
// mViewFlipper.removeAllViews();
// int i = 0;
// while (i < noticeList.size()) {
// RelativeLayout showView = (RelativeLayout) LayoutInflater.from(mContext).inflate(R.layout.notice_item_view, null);
// TextView btv = (TextView) showView.findViewById(R.id.b_tv);
// btv.setText(noticeList.get(i).getTitle());
// final NoticeListBean bean = noticeList.get(i);
// LayoutParams layoutParams = new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT);
// mViewFlipper.addView(showView, layoutParams);
// showView.setOnClickListener(new OnClickListener() {
// @Override
// public void onClick(View v) {
// if (bean.getType().equals("1") || bean.getType().equals("2")) {
// //打开webView
// Intent intent = new Intent(mContext, CommonWebViewActivity.class);
// intent.putExtra(IntentCode.COMMON_WEB_VIEW_TITLE,bean.getTitle());
// intent.putExtra(IntentCode.COMMON_WEB_VIEW_URL, bean.getLink());
// mContext.startActivity(intent);
// } else if (bean.getType().equals("3")) {
// ToastUtil.makeText(mContext, "进入内容详情页 " + bean.getTitle());
// }
// }
// });
// i++;
// }
// }
//
//}
|
[
"543126764@qq.com"
] |
543126764@qq.com
|
|
ec2d1acdc16b17a30036a524962a15f927e28288
|
bb9c8fabaa82d9153e07acc1b169a5e020314bcc
|
/Gene4x/ARACNE/src/org/geworkbench/bison/algorithm/discovery/DSDiscoveryStatus.java
|
421cd010337d03f7cfca13019574b87aac714e82
|
[] |
no_license
|
casperenghuus/6878
|
ae94f85f8857eeb61d8e252e556175c9a1cdddce
|
a4099ecd6efbae93601196c44156c91e9ca45375
|
refs/heads/master
| 2021-01-13T09:36:48.912196
| 2016-12-15T16:27:42
| 2016-12-15T16:27:42
| 72,019,199
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 584
|
java
|
package org.geworkbench.bison.algorithm.discovery;
/**
* <p>Title: caWorkbench</p>
* <p/>
* <p>Description: Modular Application Framework for Gene Expession, Sequence and Genotype Analysis</p>
* <p/>
* <p>Copyright: Copyright (c) 2003 -2004</p>
* <p/>
* <p>Company: Columbia University</p>
*
* @author not attributable
* @version 3.0
*/
public interface DSDiscoveryStatus {
// public boolean getBusy();
public double getPercentDone();
public int getPatternNo();
public int getCaseSupport();
public int getCtrlSupport();
}
|
[
"jchtt@arcor.de"
] |
jchtt@arcor.de
|
9f10c0646cc15c1d0058c8c534f6e62c60c1b3de
|
8238bc5b3398bca1bdfab9a18225eb3fbd893cfd
|
/pickerview/build/generated/not_namespaced_r_class_sources/debug/generateDebugRFile/out/com/tencent/bugly/nativecrashreport/R.java
|
eda83e3c47d671998f236970f6e18ec53f0c25f7
|
[] |
no_license
|
SetAdapter/MoveNurse
|
2a890ff9a456b9284df69f44fe2616bb306de386
|
c4770363d3b136cbe1a3cf1237d39c07151be2af
|
refs/heads/master
| 2020-04-23T14:02:05.946825
| 2019-02-18T05:12:30
| 2019-02-18T05:12:30
| 171,218,203
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 398
|
java
|
/* AUTO-GENERATED FILE. DO NOT MODIFY.
*
* This class was automatically generated by the
* gradle plugin from the resource data it found. It
* should not be modified by hand.
*/
package com.tencent.bugly.nativecrashreport;
public final class R {
private R() {}
public static final class string {
private string() {}
public static int app_name = 0x7f150023;
}
}
|
[
"383411934@qq.com"
] |
383411934@qq.com
|
d707ee2d8cb7eaeae23b0d56bfac6df1249a0f7f
|
97e8970383c75a31a7b35cea202f17809ac9f980
|
/org/telegram/ui/NotificationsExceptionsActivity$SearchAdapter$$Lambda$1.java
|
a4d8f0e36e1b1af4a9b798a8e0e54b6eb7a938e1
|
[] |
no_license
|
tgapps/android
|
27116d389c48bd3a55804c86e9a7c2e0cf86a86c
|
d061b97e4bb0f532cc141ac5021e3329f4214202
|
refs/heads/master
| 2018-11-13T20:41:30.297252
| 2018-09-03T16:09:46
| 2018-09-03T16:09:46
| 113,666,719
| 9
| 2
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 664
|
java
|
package org.telegram.ui;
import java.util.ArrayList;
final /* synthetic */ class NotificationsExceptionsActivity$SearchAdapter$$Lambda$1 implements Runnable {
private final SearchAdapter arg$1;
private final ArrayList arg$2;
private final ArrayList arg$3;
NotificationsExceptionsActivity$SearchAdapter$$Lambda$1(SearchAdapter searchAdapter, ArrayList arrayList, ArrayList arrayList2) {
this.arg$1 = searchAdapter;
this.arg$2 = arrayList;
this.arg$3 = arrayList2;
}
public void run() {
this.arg$1.lambda$updateSearchResults$2$NotificationsExceptionsActivity$SearchAdapter(this.arg$2, this.arg$3);
}
}
|
[
"telegram@daniil.it"
] |
telegram@daniil.it
|
b36397ff1721c54ce413b4b7d34f2cad24961e65
|
fa91450deb625cda070e82d5c31770be5ca1dec6
|
/Diff-Raw-Data/24/24_072ce8a562bcff37c6c2916de52f0f872ad68f1e/EHockeyApplication/24_072ce8a562bcff37c6c2916de52f0f872ad68f1e_EHockeyApplication_s.java
|
1f72fa75e77ab3baa91e83315e51f636a3fe83b5
|
[] |
no_license
|
zhongxingyu/Seer
|
48e7e5197624d7afa94d23f849f8ea2075bcaec0
|
c11a3109fdfca9be337e509ecb2c085b60076213
|
refs/heads/master
| 2023-07-06T12:48:55.516692
| 2023-06-22T07:55:56
| 2023-06-22T07:55:56
| 259,613,157
| 6
| 2
| null | 2023-06-22T07:55:57
| 2020-04-28T11:07:49
| null |
UTF-8
|
Java
| false
| false
| 5,753
|
java
|
package ar.noxit.ehockey.web.app;
import ar.noxit.ehockey.main.StartJetty;
import ar.noxit.ehockey.web.pages.HomePage;
import ar.noxit.ehockey.web.pages.authentication.AuthSession;
import ar.noxit.ehockey.web.pages.authentication.LoginPage;
import ar.noxit.ehockey.web.pages.base.MensajePage;
import ar.noxit.ehockey.web.pages.buenafe.EditarListaBuenaFePage;
import ar.noxit.ehockey.web.pages.buenafe.ListaBuenaFePage;
import ar.noxit.ehockey.web.pages.buenafe.VerListaBuenaFePage;
import ar.noxit.ehockey.web.pages.fechahora.FechaHoraPage;
import ar.noxit.ehockey.web.pages.jugadores.JugadorAltaPage;
import ar.noxit.ehockey.web.pages.jugadores.JugadorBajaPage;
import ar.noxit.ehockey.web.pages.jugadores.JugadorModificarPage;
import ar.noxit.ehockey.web.pages.jugadores.JugadorPage;
import ar.noxit.ehockey.web.pages.jugadores.JugadorVerPage;
import ar.noxit.ehockey.web.pages.partido.PartidoPage;
import ar.noxit.ehockey.web.pages.planilla.ModificarPlanillaPage;
import ar.noxit.ehockey.web.pages.planilla.PlanillaPage;
import ar.noxit.ehockey.web.pages.planilla.PlanillaPrecargadaPage;
import ar.noxit.ehockey.web.pages.planilla.PlanillaPrinterFriendly;
import ar.noxit.ehockey.web.pages.tablaposiciones.TablaPosicionesPage;
import ar.noxit.ehockey.web.pages.torneo.ListadoTorneoPage;
import ar.noxit.ehockey.web.pages.torneo.NuevoTorneoPage;
import ar.noxit.ehockey.web.pages.torneo.ReprogramacionPartidoPage;
import ar.noxit.ehockey.web.pages.torneo.TorneoPage;
import ar.noxit.ehockey.web.pages.torneo.VerPartidosPage;
import ar.noxit.ehockey.web.pages.usuarios.AltaUsuarioPage;
import ar.noxit.ehockey.web.pages.usuarios.EditarUsuarioPage;
import ar.noxit.ehockey.web.pages.usuarios.ListaUsuariosPage;
import org.apache.commons.lang.Validate;
import org.apache.wicket.authentication.AuthenticatedWebApplication;
import org.apache.wicket.authentication.AuthenticatedWebSession;
import org.apache.wicket.markup.html.WebPage;
import org.apache.wicket.request.target.coding.HybridUrlCodingStrategy;
import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
/**
* Application object for your web application. If you want to run this
* application without deploying, run the Start class.
*
* @see StartJetty.myproject.Start#main(String[])
*/
public class EHockeyApplication extends AuthenticatedWebApplication {
private final String appMode;
/**
* Constructor
*/
public EHockeyApplication(String appMode) {
Validate.notNull(appMode, "application mode cannot be null");
this.appMode = appMode;
}
@Override
protected void init() {
super.init();
addComponentInstantiationListener(new SpringComponentInjector(this));
mount(new HybridUrlCodingStrategy("/listabuenafe", ListaBuenaFePage.class, false));
mount(new HybridUrlCodingStrategy("/listabuenafe/ver", VerListaBuenaFePage.class, false));
mount(new HybridUrlCodingStrategy("/listabuenafe/editar", EditarListaBuenaFePage.class, false));
mount(new HybridUrlCodingStrategy("/partidos", PartidoPage.class, false));
mount(new HybridUrlCodingStrategy("/planillas/final", PlanillaPage.class, false));
mount(new HybridUrlCodingStrategy("/planillas/print", PlanillaPrinterFriendly.class, false));
mount(new HybridUrlCodingStrategy("/planillas/precargada", PlanillaPrecargadaPage.class, false));
mount(new HybridUrlCodingStrategy("/planillas/modificar", ModificarPlanillaPage.class, false));
mount(new HybridUrlCodingStrategy("/torneos", TorneoPage.class, false));
mount(new HybridUrlCodingStrategy("/torneos/crear", NuevoTorneoPage.class, false));
mount(new HybridUrlCodingStrategy("/torneos/listado", ListadoTorneoPage.class, false));
mount(new HybridUrlCodingStrategy("/torneos/ver", VerPartidosPage.class, false));
mount(new HybridUrlCodingStrategy("/partidos/reprogramar", ReprogramacionPartidoPage.class, false));
mount(new HybridUrlCodingStrategy("/jugadores", JugadorPage.class, false));
mount(new HybridUrlCodingStrategy("/jugadores/alta", JugadorAltaPage.class, false));
mount(new HybridUrlCodingStrategy("/jugadores/baja", JugadorBajaPage.class, false));
mount(new HybridUrlCodingStrategy("/jugadores/modificar", JugadorModificarPage.class, false));
mount(new HybridUrlCodingStrategy("/jugadores/ver", JugadorVerPage.class, false));
mount(new HybridUrlCodingStrategy("/tablaposiciones", TablaPosicionesPage.class, false));
mount(new HybridUrlCodingStrategy("/usuarios/listado", ListaUsuariosPage.class, false));
mount(new HybridUrlCodingStrategy("/usuarios/alta", AltaUsuarioPage.class, false));
mount(new HybridUrlCodingStrategy("/usuarios/modificar", EditarUsuarioPage.class, false));
mount(new HybridUrlCodingStrategy("/resultado", MensajePage.class, false));
mount(new HybridUrlCodingStrategy("/fechahora", FechaHoraPage.class, false));
mount(new HybridUrlCodingStrategy("/login", LoginPage.class, false));
// getApplicationSettings().setAccessDeniedPage(accessDeniedPage)
}
/**
* @see wicket.Application#getHomePage()
*/
@Override
public Class<? extends WebPage> getHomePage() {
return HomePage.class;
}
@Override
public String getConfigurationType() {
return appMode;
}
@Override
protected Class<? extends WebPage> getSignInPageClass() {
return LoginPage.class;
}
@Override
protected Class<? extends AuthenticatedWebSession> getWebSessionClass() {
return AuthSession.class;
}
}
|
[
"yuzhongxing88@gmail.com"
] |
yuzhongxing88@gmail.com
|
0cd0990110e9c3a89ad7982d7a8e49581362f04d
|
18cc9453ebc3b58309aa6a05990ba6393a322df0
|
/core/src/main/java/ru/prolib/aquila/core/data/timeframe/ZTFMinutes.java
|
c2951253206e413fd290760fba0adca4aff0a3f4
|
[] |
no_license
|
robot-aquila/aquila
|
20ef53d813074e2346bfbd6573ffb0737bef5412
|
056af30a3610366fe47d97d0c6d53970e3ee662b
|
refs/heads/develop
| 2022-11-30T01:54:52.653013
| 2020-12-07T00:18:01
| 2020-12-07T00:18:01
| 20,706,073
| 3
| 2
| null | 2022-11-24T08:58:08
| 2014-06-11T00:00:34
|
Java
|
UTF-8
|
Java
| false
| false
| 2,732
|
java
|
package ru.prolib.aquila.core.data.timeframe;
import java.time.Instant;
import java.time.LocalDateTime;
import java.time.LocalTime;
import java.time.ZoneId;
import java.time.ZonedDateTime;
import java.time.temporal.ChronoUnit;
import org.apache.commons.lang3.builder.EqualsBuilder;
import org.apache.commons.lang3.builder.HashCodeBuilder;
import org.threeten.extra.Interval;
import ru.prolib.aquila.core.data.TFrame;
/**
* Minutes time frame with time zone.
*/
public class ZTFMinutes extends AbstractZTFrame {
/**
* Create minutes timeframe in specified time zone.
* <p>
* @param length - number of minutes in interval
* @param zoneID - time zone
*/
public ZTFMinutes(int length, ZoneId zoneID) {
super(length, ChronoUnit.MINUTES, zoneID);
if ( length <= 0 || length > 1440 ) {
throw new IllegalArgumentException("Invalid length specified: " + length);
}
}
/**
* Create minute timeframe in UTC time zone.
* <p>
* @param length - number of minutes in interval
*/
public ZTFMinutes(int length) {
this(length, ZoneId.of("UTC"));
}
@Override
public Interval getInterval(Instant timestamp) {
LocalDateTime time = LocalDateTime.ofInstant(timestamp, zoneID);
long secondOfDay = ChronoUnit.MINUTES.between(LocalTime.MIDNIGHT,
time.toLocalTime()) / length * length * 60;
LocalDateTime from = LocalDateTime.of(time.toLocalDate(),
LocalTime.ofSecondOfDay(secondOfDay));
LocalDateTime to = from.plusMinutes(length);
if ( to.toLocalDate().isAfter(from.toLocalDate()) ) {
// Конец периода указывает на дату следующего дня.
// В таком случае конец интервала выравнивается по началу след. дня.
to = LocalDateTime.of(from.toLocalDate().plusDays(1), LocalTime.MIDNIGHT);
}
return Interval.of(ZonedDateTime.of(from, zoneID).toInstant(),
ZonedDateTime.of(to, zoneID).toInstant());
}
@Override
public boolean isIntraday() {
return true;
}
@Override
public boolean equals(Object other) {
if ( other == this ) {
return true;
}
if ( other == null || other.getClass() != ZTFMinutes.class ) {
return false;
}
ZTFMinutes o = (ZTFMinutes) other;
return new EqualsBuilder()
.append(o.length, length)
.append(o.zoneID, zoneID)
.isEquals();
}
@Override
public int hashCode() {
return new HashCodeBuilder(859, 175)
.append(length)
.append(zoneID)
.toHashCode();
}
@Override
public String toString() {
return "M" + length + "[" + zoneID + "]";
}
@Override
public TFrame toTFrame() {
return new TFMinutes(length);
}
}
|
[
"robot-aquila@hotmail.com"
] |
robot-aquila@hotmail.com
|
b5c3c71ad37456d941b6ef6e1c78160407e2d123
|
92225460ebca1bb6a594d77b6559b3629b7a94fa
|
/src/com/kingdee/eas/fdc/sellhouse/SHEFunctionSetEntryInfo.java
|
685d2546bc57c129a10743145431482209f560c8
|
[] |
no_license
|
yangfan0725/sd
|
45182d34575381be3bbdd55f3f68854a6900a362
|
39ebad6e2eb76286d551a9e21967f3f5dc4880da
|
refs/heads/master
| 2023-04-29T01:56:43.770005
| 2023-04-24T05:41:13
| 2023-04-24T05:41:13
| 512,073,641
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 331
|
java
|
package com.kingdee.eas.fdc.sellhouse;
import java.io.Serializable;
public class SHEFunctionSetEntryInfo extends AbstractSHEFunctionSetEntryInfo implements Serializable
{
public SHEFunctionSetEntryInfo()
{
super();
}
protected SHEFunctionSetEntryInfo(String pkField)
{
super(pkField);
}
}
|
[
"yfsmile@qq.com"
] |
yfsmile@qq.com
|
80d3c2b602b9e69497ec0c1f150ed6a96881dea1
|
c89333d091f152c8c36623065cf6974997530876
|
/sa.elm.ob.utility/src/sa/elm/ob/utility/util/InvoiceApprovalTable.java
|
9f91d638a3ce2b16bfd1715ae06424cdc2ec3fc4
|
[] |
no_license
|
Orkhan42/openbravotest
|
24cb0f35986732c41a21963d7aa7a0910e7b4afd
|
82c7bfb60dda7a30be276a2b07e5ca2b4a92c585
|
refs/heads/master
| 2023-03-01T00:35:37.463178
| 2021-02-04T12:55:45
| 2021-02-04T12:55:45
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 378
|
java
|
package sa.elm.ob.utility.util;
/**
* @author Gopinagh. R
*/
public class InvoiceApprovalTable {
public static final String INVOICE_HISTORY = "efin_purchasein_app_hist";
public static final String INVOICE_HEADER_COLUMN = "c_invoice_id";
public static final String INVOICE_DOCACTION_COLUMN = "purchaseaction";
public static final String INVOICE_TABLE = "c_invoice";
}
|
[
"laiquddin.syed83@gmail.com"
] |
laiquddin.syed83@gmail.com
|
20f2f7a2485566bdd98aaa66ac7d06bde35399a7
|
44b204b157f5532210cac769ceab3c4907efbb33
|
/jbeanbox/src/main/java/com/github/drinkjava2/cglib3_2_0/reflect/FastConstructor.java
|
9b1f983e491d1add77916a5108c2553953e8516a
|
[
"Apache-2.0"
] |
permissive
|
orb1t/jBeanBox
|
0438533dd0026d9b8cdb24625df7034c67338667
|
acea0d0f3ff4d4dec6a19144941fd342a1947329
|
refs/heads/master
| 2020-04-07T23:55:19.421579
| 2018-11-21T09:17:34
| 2018-11-21T09:17:34
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,540
|
java
|
/*
* Copyright 2003 The Apache Software Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.github.drinkjava2.cglib3_2_0.reflect;
import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
@SuppressWarnings({"rawtypes" })
public class FastConstructor extends FastMember
{
FastConstructor(FastClass fc, Constructor constructor) {
super(fc, constructor, fc.getIndex(constructor.getParameterTypes()));
}
public Class[] getParameterTypes() {
return ((Constructor)member).getParameterTypes();
}
public Class[] getExceptionTypes() {
return ((Constructor)member).getExceptionTypes();
}
public Object newInstance() throws InvocationTargetException {
return fc.newInstance(index, null);
}
public Object newInstance(Object[] args) throws InvocationTargetException {
return fc.newInstance(index, args);
}
public Constructor getJavaConstructor() {
return (Constructor)member;
}
}
|
[
"yong9981@gmail.com"
] |
yong9981@gmail.com
|
901bcf2b94d952559861111ff0879116a8be9152
|
1cbf46c147b09a878235da8010f427eb2447bab5
|
/src/main/java/ljtao/book_study/effective_java/source_code/chapter6/item39/annotationwithparameter/ExceptionTest.java
|
eeb68284bfdc2caeefd7183d378922040f8dfbb7
|
[] |
no_license
|
mathLjtao/MyJavaStudy
|
54b90fbb0f285a611b73d72477a605d875563716
|
d9a934e95b2f24bf854a4c359dd04d3fb8acd0d9
|
refs/heads/master
| 2022-12-22T02:01:24.856371
| 2021-09-16T13:15:20
| 2021-09-16T13:15:20
| 188,509,645
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 432
|
java
|
package ljtao.book_study.effective_java.source_code.chapter6.item39.annotationwithparameter;
// Annotation type with a parameter (Page 183)
import java.lang.annotation.*;
/**
* Indicates that the annotated method is a test method that
* must throw the designated exception to succeed.
*/
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.METHOD)
public @interface ExceptionTest {
Class<? extends Throwable> value();
}
|
[
"43426976+mathLjtao@users.noreply.github.com"
] |
43426976+mathLjtao@users.noreply.github.com
|
ffca1c88990fe3e8c7fffba5e2678241b103ab02
|
9d864f5a053b29d931b4c2b4f773e13291189d27
|
/src/config/localization/bundles/src/java/org/sakaiproject/localization/util/SiteemaconProperties.java
|
f853100336676e072823d024ffb26866609a2d6b
|
[] |
no_license
|
kyeddlapalli/sakai-cle
|
b1bd1e4431d8d96b6b650bfe9454eacd3e7042b2
|
1f06c7ac69c7cbe731c8d175d557313d0fb34900
|
refs/heads/master
| 2021-01-18T10:57:25.449065
| 2014-01-12T21:18:15
| 2014-01-12T21:18:15
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,442
|
java
|
/*****************************************************************************
* $URL: https://source.sakaiproject.org/svn/config/trunk/localization/bundles/src/java/org/sakaiproject/localization/util/SiteemaconProperties.java $
* $Id: SiteemaconProperties.java 105079 2012-02-24 23:08:11Z ottenhoff@longsight.com $
*****************************************************************************
*
* Copyright (c) 2008, 2009 The Sakai Foundation
*
* Licensed under the Educational Community License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.opensource.org/licenses/ECL-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*****************************************************************************/
package org.sakaiproject.localization.util;
/**
* This class should be configured as a "Siteemacon" bundles bean
* (see components.xml) in order to provide the context for
* the kernel to load the localized siteemacon_*.properties files.
*/
public class SiteemaconProperties {
public SiteemaconProperties() {
// constructor
}
}
|
[
"noah@botimer.net"
] |
noah@botimer.net
|
30e36d885b1f7ef1febb8eb2ec44869bcda21e54
|
29f150be2126e4658f1eb156c03d6385bbc7b4bf
|
/jp.ac.jaist.kslab.sb.marte.edit/src/MARTE/MARTE_DesignModel/GCM/provider/DataEventItemProvider.java
|
22838bbac80b6c7567b8dfe2af81d551969880da
|
[] |
no_license
|
s-hosoai/solderbullet
|
18b9dc28944e247882b1affbdb52897da3bd5257
|
73ceae859e5877911a9d5e06e6de0b81bcdf3a2a
|
refs/heads/master
| 2020-12-25T16:01:55.654916
| 2016-07-02T08:53:19
| 2016-07-02T08:53:19
| 62,442,619
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,868
|
java
|
/**
*/
package MARTE.MARTE_DesignModel.GCM.provider;
import MARTE.MARTE_DesignModel.GCM.GCMPackage;
import MARTE.MARTE_Foundations.NFPs.provider.MARTE_sbEditPlugin;
import java.util.Collection;
import java.util.List;
import org.eclipse.emf.common.notify.AdapterFactory;
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.util.ResourceLocator;
import org.eclipse.emf.edit.provider.ComposeableAdapterFactory;
import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
import org.eclipse.emf.edit.provider.IItemLabelProvider;
import org.eclipse.emf.edit.provider.IItemPropertySource;
import org.eclipse.emf.edit.provider.IStructuredItemContentProvider;
import org.eclipse.emf.edit.provider.ITreeItemContentProvider;
import org.eclipse.emf.edit.provider.ItemProviderAdapter;
/**
* This is the item provider adapter for a {@link MARTE.MARTE_DesignModel.GCM.DataEvent} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public class DataEventItemProvider
extends ItemProviderAdapter
implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
IItemLabelProvider,
IItemPropertySource {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public DataEventItemProvider(AdapterFactory adapterFactory) {
super(adapterFactory);
}
/**
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public List getPropertyDescriptors(Object object) {
if (itemPropertyDescriptors == null) {
super.getPropertyDescriptors(object);
addBase_AnyReceiveEventPropertyDescriptor(object);
addClassifierPropertyDescriptor(object);
}
return itemPropertyDescriptors;
}
/**
* This adds a property descriptor for the Base Any Receive Event feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected void addBase_AnyReceiveEventPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_DataEvent_base_AnyReceiveEvent_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_DataEvent_base_AnyReceiveEvent_feature", "_UI_DataEvent_type"),
GCMPackage.Literals.DATA_EVENT__BASE_ANY_RECEIVE_EVENT,
true,
false,
true,
null,
null,
null));
}
/**
* This adds a property descriptor for the Classifier feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected void addClassifierPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
(createItemPropertyDescriptor
(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
getResourceLocator(),
getString("_UI_DataEvent_classifier_feature"),
getString("_UI_PropertyDescriptor_description", "_UI_DataEvent_classifier_feature", "_UI_DataEvent_type"),
GCMPackage.Literals.DATA_EVENT__CLASSIFIER,
true,
false,
true,
null,
null,
null));
}
/**
* This returns DataEvent.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public Object getImage(Object object) {
return overlayImage(object, getResourceLocator().getImage("full/obj16/DataEvent"));
}
/**
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public String getText(Object object) {
return getString("_UI_DataEvent_type");
}
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public void notifyChanged(Notification notification) {
updateChildren(notification);
super.notifyChanged(notification);
}
/**
* This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) {
super.collectNewChildDescriptors(newChildDescriptors, object);
}
/**
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
public ResourceLocator getResourceLocator() {
return MARTE_sbEditPlugin.INSTANCE;
}
}
|
[
"shintaro.hosoai@gmail.com"
] |
shintaro.hosoai@gmail.com
|
0e6d0de5d18686c49ea40d3edfabb58aa008cbb1
|
f12ae2d71115fe4d8aa04bdca261b72cf5496399
|
/Day03/src/com/wanchenyang/homework/Test04.java
|
804f20ee2155559e0b1510801fcc0b45f0b16ff4
|
[] |
no_license
|
wanchenyang521/iGeek
|
0fe5323839cd669dc5a060e00013f5318ffb7ede
|
420c76a0c2ab92b16c673774dc008cf0eeabc07e
|
refs/heads/master
| 2020-04-26T07:19:47.852086
| 2019-04-23T03:11:12
| 2019-04-23T03:11:12
| 173,390,991
| 2
| 0
| null | null | null | null |
GB18030
|
Java
| false
| false
| 1,260
|
java
|
package com.wanchenyang.homework;
import java.util.Scanner;
/**
*
* @author: 晨阳
* @date: 2019年3月1日 下午4:16:20
* @version V1.0
* @Description: 从键盘上录入一个大于100的三位数,求出100到该数字之间满足如下要求的数字之和: 1.数字的个位数不为7;
* 2.数字的十位数不为5; 3.数字的百位数不为3;
*/
public class Test04
{
public static void main(String[] args)
{
Scanner input = new Scanner(System.in);
System.out.println("请输入一个大于100的三位数,输入0结束");
int num = input.nextInt();
while(true)
{
if(num==0)
{
break;
}
if (num <= 100)
{
System.out.println("输入非法,请输入一个大于100的三位数");
num = input.nextInt();
}
else
{
int num1 = 0;
int num2 = 0;
int num3 = 0;
int sum = 0;
for (int i = 100; i <= num; i++)
{
num1 = i % 10;
num2 = i / 10 % 10;
num3 = i / 100 % 10;
if (num1 != 7 && num2 != 5 && num3 != 3)
{
System.out.println(i);
sum += i;
}
}
System.out.println("和为:" +sum);
System.out.println("请输入一个大于100的三位数,输入0结束");
num = input.nextInt();
}
}
}
}
|
[
"wan1183254286@icloud.com"
] |
wan1183254286@icloud.com
|
682ebb4d0cea34300fd9603a0e20dca8866b36bd
|
1748053ae0229c37da6eec429b9f47fc9d836f54
|
/shengka-media-user/shengka-media-user-provider/src/main/java/com/geek/shengka/user/entity/vo/SkCategoryVO.java
|
87dc6316d8d65b641f51224a22b63c5161909f75
|
[] |
no_license
|
chaochaoGT/shangka
|
54d2a436a2a0348b7d4f2a994dc657dd3a3e8fa2
|
e43f7d7c26db15974e0ddc612a3ee16c9360b36a
|
refs/heads/master
| 2023-02-28T03:37:11.085305
| 2021-02-05T13:15:36
| 2021-02-05T13:15:36
| 336,273,377
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 902
|
java
|
package com.geek.shengka.user.entity.vo;
import lombok.Data;
import java.util.Date;
/**
* @Filename: SkCategoryVO
* @Description:
* @Version: 1.0
* @Author: wangchao
* @Email: wangchao@hellogeek.com
* @date: 2019/8/1 ;
*/
@Data
public class SkCategoryVO {
/**
* 主键
*/
private Long id;
/**
* 频道名称
*/
private String categoryName;
/**
* 0-禁用,1-启用
*/
private Integer enable;
/**
* icon图片
*/
private String iconUrl;
/**
* 排序
*/
private Integer seq;
/**
* 更新时间
*/
private Date updateTime;
/**
* 创建时间
*/
private Date createTime;
/**
* 创建人
*/
private String createBy;
/**
* 更新人
*/
private String updateBy;
/**
* 是否自己的
*/
private int isMyself;
}
|
[
"952904879@qq.com"
] |
952904879@qq.com
|
0a6b13a491c494bcf2df9c57457053614cc412ce
|
8a07a8ea416c0f2a587b1220187c9919cb9b18ca
|
/zsyc-interface/src/main/java/com/zsyc/platform/entity/PlatformNews.java
|
e5872fbe103bae476f918b180d09ecd3fb6ce082
|
[] |
no_license
|
ningjm/zsyc
|
ee462a59675996ae6e5e97bd1ad619a4ca209819
|
dc7c60e82f4a6adcdf743ebeaa15aab16a48c9a2
|
refs/heads/master
| 2020-05-07T21:52:57.775161
| 2019-04-12T03:36:58
| 2019-04-12T03:36:58
| 180,921,780
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,208
|
java
|
package com.zsyc.platform.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.zsyc.framework.base.BaseBean;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import java.time.LocalDateTime;
/**
* <p>
*
* </p>
*
* @author MP
* @since 2019-03-11
*/
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
public class PlatformNews extends BaseBean {
private static final long serialVersionUID = 1L;
/**
* 主键
*/
@TableId(value = "id", type = IdType.AUTO)
private Long id;
/**
* 新闻标题
*/
private String title;
/**
* 新闻内容
*/
private String content;
/**
* 多个图片链接,号分割
*/
private String imgUrl;
/**
* 创建人ID
*/
private Long createUserId;
/**
* 创建时间
*/
private LocalDateTime createTime;
/**
* 更新操作的用户id
*/
private Long updateUserId;
/**
* 更新时间
*/
private LocalDateTime updateTime;
/**
* 是否删除
*/
private Integer isDel;
}
|
[
"2719334283@qq.com"
] |
2719334283@qq.com
|
9d9846b9f5ad809574fc131116d76a620349090d
|
7fa2b0e9e831510eb968329d2f22edcdd7470ea0
|
/app/src/main/java/com/cyl/music_hnust/bean/music/Lrc.java
|
820624894e3a0e93fdf997f612855b859ba8fec4
|
[] |
no_license
|
mengweilong8/MusicLake
|
c2f1a428b0c7a1f9f460288695b23ea87696a529
|
acfcece0b4d0d112f475393c8e938b57f9d2c6b5
|
refs/heads/master
| 2020-03-17T16:13:37.701853
| 2017-11-08T14:51:49
| 2017-11-08T14:51:49
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 353
|
java
|
package com.cyl.music_hnust.bean.music;
/**
* 作者:yonglong on 2016/10/25 00:02
* 邮箱:643872807@qq.com
* 版本:2.5
*/
public class Lrc {
private String lrcContent;
public String getLrcContent() {
return lrcContent;
}
public void setLrcContent(String lrcContent) {
this.lrcContent = lrcContent;
}
}
|
[
"caiyonglong@live.com"
] |
caiyonglong@live.com
|
249f1a85e155c120ba6fc5eb54015d2c4815b230
|
6d60a8adbfdc498a28f3e3fef70366581aa0c5fd
|
/codebase/dataset/x/260_frag2.java
|
bfe683eaf6b1b563b2b8bb15ca7120f9ea0148c1
|
[] |
no_license
|
rayhan-ferdous/code2vec
|
14268adaf9022d140a47a88129634398cd23cf8f
|
c8ca68a7a1053d0d09087b14d4c79a189ac0cf00
|
refs/heads/master
| 2022-03-09T08:40:18.035781
| 2022-02-27T23:57:44
| 2022-02-27T23:57:44
| 140,347,552
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 573
|
java
|
private void refreshFieldUrl(IBaseObject field, String url) {
field.setAttribute(IDatafield.URL, url);
if (field instanceof IModuleList) {
IModuleList<IModule> list = (IModuleList) field;
for (int i = 0; i < list.size(); i++) refreshFieldUrl(list.get(i), url + IDatafield.URL_DELIMITER + i);
} else if (field instanceof IModule) {
IModule entity = (IModule) field;
for (String key : entity.keySet()) refreshFieldUrl(entity.get(key), url + IDatafield.URL_DELIMITER + key);
}
}
|
[
"aaponcseku@gmail.com"
] |
aaponcseku@gmail.com
|
32eb73145c31e30c7da2f6ef3cbbafe6d06d342e
|
a160e717506a2b6babd9b95500bb017297db7f71
|
/src/main/java/ch06/instructions/stores/fstore/FSTORE.java
|
d499d16540d06106358b3fa5a4388e6180cea89b
|
[] |
no_license
|
zhaohan6357/JVM_java
|
cb93455143d9f0b879c766a8dec593934be3dc9b
|
fe7b1b3fde1fe4e4b9098b4f3ae86e02b68adca1
|
refs/heads/master
| 2020-03-22T10:41:04.897568
| 2018-08-09T02:17:11
| 2018-08-09T02:17:34
| 139,919,863
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 324
|
java
|
package ch06.instructions.stores.fstore;
import ch06.instructions.base.instruction.Index8Instruction;
import ch06.instructions.stores.fstore._FSTORE;
import ch06.rtda.Frame;
public class FSTORE extends Index8Instruction {
@Override
public void Execute(Frame frame) {
_FSTORE._fstore(frame,index);
}
}
|
[
"zhaohan6357@163.com"
] |
zhaohan6357@163.com
|
24d573218fb444d9c09b4c16c7a531319396db94
|
3a59bd4f3c7841a60444bb5af6c859dd2fe7b355
|
/sources/com/google/android/gms/internal/ads/zznp.java
|
32ae630956d266a403ede4fcdcc5aacd25462763
|
[] |
no_license
|
sengeiou/KnowAndGo-android-thunkable
|
65ac6882af9b52aac4f5a4999e095eaae4da3c7f
|
39e809d0bbbe9a743253bed99b8209679ad449c9
|
refs/heads/master
| 2023-01-01T02:20:01.680570
| 2020-10-22T04:35:27
| 2020-10-22T04:35:27
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 145
|
java
|
package com.google.android.gms.internal.ads;
public interface zznp {
void zza(zznu zznu);
zznw zzd(int i, int i2);
void zzfi();
}
|
[
"joshuahj.tsao@gmail.com"
] |
joshuahj.tsao@gmail.com
|
77804a648641853cfa1fa23a59d642502fbc2611
|
fa91450deb625cda070e82d5c31770be5ca1dec6
|
/Diff-Raw-Data/11/11_4d9d9dbe8764314aaee9e30ca550f971c3359f53/ExtractorXML/11_4d9d9dbe8764314aaee9e30ca550f971c3359f53_ExtractorXML_t.java
|
5fa51bbc124bf006eabae3c64fca6b59fd5433d9
|
[] |
no_license
|
zhongxingyu/Seer
|
48e7e5197624d7afa94d23f849f8ea2075bcaec0
|
c11a3109fdfca9be337e509ecb2c085b60076213
|
refs/heads/master
| 2023-07-06T12:48:55.516692
| 2023-06-22T07:55:56
| 2023-06-22T07:55:56
| 259,613,157
| 6
| 2
| null | 2023-06-22T07:55:57
| 2020-04-28T11:07:49
| null |
UTF-8
|
Java
| false
| false
| 3,990
|
java
|
/*
* This file is part of the Heritrix web crawler (crawler.archive.org).
*
* Licensed to the Internet Archive (IA) by one or more individual
* contributors.
*
* The IA licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.archive.modules.extractor;
import java.io.IOException;
import java.util.logging.Logger;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import org.apache.commons.httpclient.URIException;
import org.apache.commons.lang.StringEscapeUtils;
import org.archive.io.ReplayCharSequence;
import org.archive.modules.CrawlURI;
import org.archive.util.ArchiveUtils;
/**
* A simple extractor which finds HTTP URIs inside XML/RSS files,
* inside attribute values and simple elements (those with only
* whitespace + HTTP URI + whitespace as contents)
*
* @author gojomo
*
**/
public class ExtractorXML extends ContentExtractor {
private static final long serialVersionUID = 3L;
private static Logger logger =
Logger.getLogger(ExtractorXML.class.getName());
static final Pattern XML_URI_EXTRACTOR = Pattern.compile(
"(?i)[\"\'>]\\s*(http:[^\\s\"\'<>]+)\\s*[\"\'<]");
// GROUPS:
// (G1) URI
/**
* @param name
*/
public ExtractorXML() {
}
@Override
protected boolean shouldExtract(CrawlURI curi) {
String mimeType = curi.getContentType();
if (mimeType == null) {
return false;
}
if ((mimeType.toLowerCase().indexOf("xml") < 0)
&& (!curi.toString().toLowerCase().endsWith(".rss"))
&& (!curi.toString().toLowerCase().endsWith(".xml"))) {
return false;
}
return true;
}
/**
* @param curi Crawl URI to process.
*/
@Override
protected boolean innerExtract(CrawlURI curi) {
ReplayCharSequence cs = null;
try {
cs = curi.getRecorder().getReplayCharSequence();
numberOfLinksExtracted.addAndGet(processXml(this, curi, cs));
// Set flag to indicate that link extraction is completed.
return true;
} catch (IOException e) {
logger.severe("Failed getting ReplayCharSequence: " + e.getMessage());
} finally {
ArchiveUtils.closeQuietly(cs);
}
return false;
}
public static long processXml(Extractor ext,
CrawlURI curi, CharSequence cs) {
long foundLinks = 0;
Matcher uris = null;
String xmlUri;
uris = XML_URI_EXTRACTOR.matcher(cs);
while (uris.find()) {
xmlUri = StringEscapeUtils.unescapeXml(uris.group(1));
foundLinks++;
try {
// treat as speculative, as whether context really
// intends to create a followable/fetchable URI is
// unknown
int max = ext.getExtractorParameters().getMaxOutlinks();
Link.add(curi, max, xmlUri, LinkContext.SPECULATIVE_MISC,
Hop.SPECULATIVE);
} catch (URIException e) {
// There may not be a controller (e.g. If we're being run
// by the extractor tool).
ext.logUriError(e, curi.getUURI(), xmlUri);
}
}
return foundLinks;
}
}
|
[
"yuzhongxing88@gmail.com"
] |
yuzhongxing88@gmail.com
|
83ec5cdfb8255687df25cd56892c0e924586bbbb
|
85183e4ef7b2be189e3cf9dfea35eedf25365960
|
/fs-webClient/src/main/java/com/liz/fs/fastdfs/controller/FastDFSUtils.java
|
1c3c393a7c26b0976e379fecc12d343ebb149508
|
[] |
no_license
|
lizhou828/liz-fs
|
f8dac838b6d62891b21023dc5f965ddc250235af
|
eb70c5d888376c68fbf16b80f39dcb3a36def982
|
refs/heads/master
| 2021-08-30T09:37:27.944018
| 2017-12-17T08:38:43
| 2017-12-17T08:38:43
| 111,618,644
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 6,913
|
java
|
package com.liz.fs.fastdfs.controller;
import com.liz.fs.common.utils.FileHelper;
import com.liz.fs.fastdfs.client.*;
import net.coobird.thumbnailator.Thumbnails;
import org.apache.log4j.Logger;
import java.io.File;
import java.net.URL;
/**
* Created by lizhou on 2017年11月19日 22时32分
*/
public class FastDFSUtils {
protected final static Logger logger = Logger.getLogger(FastDFSUtils.class);
protected static StorageClient1 storageClient1;
protected static TrackerServer trackerServer;
static {
/* 初始化 */
try {
ClientGlobal.initByProperties("fastdfs-client.properties");
TrackerClient tracker = new TrackerClient();
trackerServer = tracker.getConnection();
storageClient1 = new StorageClient1(trackerServer, null);
} catch (Exception e) {
logger.error("FastDFS has initialized failed! Please check config file!");
}
}
public static void main(String[] args) {
// try {
// String masterFileId = uploadFile("C:\\Users\\Administrator\\Desktop\\hashiqi.jpg");
// System.out.println(masterFileId);
// download(masterFileId, "C:\\Users\\Administrator\\Desktop\\master.png");
//
// String slaveFileId = uploadSlaveFile(masterFileId, "_244x244", "C:\\Users\\Administrator\\Desktop\\hashiqi_244x244.jpg");
// System.out.println(slaveFileId);
//
// download(slaveFileId, "C:\\Users\\Administrator\\Desktop\\slave.png");
// } catch (Exception e) {
// logger.error("upload file to FastDFS failed.", e);
// }
// try {
// /* 上传原图 */
// String orgPicUrl = "C:\\Users\\Administrator\\Desktop\\hashiqi.jpg";
// String masterFileId = uploadFile(orgPicUrl);
// System.out.println(masterFileId);
//
//
// int length = 150;
// int width = 150;
// String targetUrl = "C:\\Users\\Administrator\\Desktop\\hashiqi_" + width + "x" + length + ".jpg";
//// 压缩原图并生成
// Thumbnails.of(orgPicUrl)
// .size(width,length)
// .toFile(targetUrl);
//
// //上传压缩图
// String slaveFileId = uploadSlaveFile(masterFileId, "_" + width + "x" + length, targetUrl);
// System.out.println(slaveFileId);
// } catch (Exception e) {
// logger.error("upload file to FastDFS failed.", e);
// }
//
generateSmallPic("http://192.168.202.129","/group1/M00/00/00/wKjKgloS3u-AdYdvAABWRV3JmjY199.jpg","C:\\Users\\Administrator\\Desktop",150,150);
}
/**
* 1、先把byte已file
* @param bytes
*/
public static void generateSmallPic(byte[] bytes){
if(null == bytes || bytes.length == 0){
return;
}
int length = 150;
int width = 150;
String targetUrl = "C:\\Users\\Administrator\\Desktop\\hashiqi_" + width + "x" + length + ".jpg";
try{
String uploadTempPath = "C:\\Users\\Administrator\\Desktop\\hashiqi.jpg";
File file = FileHelper.byteToFile(bytes,uploadTempPath);
//压缩原图并生成
Thumbnails.of(file)
.size(width,length)
.toFile(targetUrl);
}catch (Exception e){
}
}
public static String generateSmallPic(String fileHost,String mainUploadFileId,String uploadPath, int width, int length){
String targetUrl = null;
try {
URL url = new URL(fileHost + "/" + mainUploadFileId);
if(!mainUploadFileId.contains(".")){
return targetUrl;
}
String fileName = mainUploadFileId.substring(mainUploadFileId.lastIndexOf("/"),mainUploadFileId.length());
if(!fileName.contains(".")){
return targetUrl;
}
String [] parts = fileName.split("\\.");
if(parts.length != 2){
return targetUrl;
}
String targetFileName = parts[0] + "_" + width + "x" + length + "." + parts[1];
targetUrl = uploadPath + File.separator + targetFileName;
// 上传图片后有延迟,需要停顿一会
Thread.sleep(500);
//压缩原图并生成
Thumbnails.of(url)
.size(width,length)
.toFile(targetUrl);
}catch (Exception e){
e.printStackTrace();
}
return targetUrl;
}
public static String uploadFile(String filePath) throws Exception{
String fileId = "";
String fileExtName = "";
if (filePath.contains(".")) {
fileExtName = filePath.substring(filePath.lastIndexOf(".") + 1);
} else {
logger.warn("Fail to upload file, because the format of filename is illegal.");
return fileId;
}
//建立连接
/*.......*/
//上传文件
try {
fileId = storageClient1.upload_file1(filePath, fileExtName, null);
} catch (Exception e) {
logger.warn("Upload file \"" + filePath + "\"fails");
}finally{
trackerServer.close();
}
return fileId;
}
public static String uploadSlaveFile(String masterFileId, String prefixName, String slaveFilePath) throws Exception{
String slaveFileId = "";
String slaveFileExtName = "";
if (slaveFilePath.contains(".")) {
slaveFileExtName = slaveFilePath.substring(slaveFilePath.lastIndexOf(".") + 1);
} else {
logger.warn("Fail to upload file, because the format of filename is illegal.");
return slaveFileId;
}
//建立连接
/*.......*/
//上传文件
try {
slaveFileId = storageClient1.upload_file1(masterFileId, prefixName, slaveFilePath, slaveFileExtName, null);
} catch (Exception e) {
logger.warn("Upload file \"" + slaveFilePath + "\"fails");
}finally{
trackerServer.close();
}
return slaveFileId;
}
public static int download(String fileId, String localFile) throws Exception{
int result = 0;
//建立连接
TrackerClient tracker = new TrackerClient();
TrackerServer trackerServer = tracker.getConnection();
StorageServer storageServer = null;
StorageClient1 client = new StorageClient1(trackerServer, storageServer);
//上传文件
try {
result = client.download_file1(fileId, localFile);
} catch (Exception e) {
logger.warn("Download file \"" + localFile + "\"fails");
}finally{
trackerServer.close();
}
System.out.println();
return result;
}
}
|
[
"lizhou828@126.com"
] |
lizhou828@126.com
|
ad4528ea17790bf5ca819af0bf05066a73e6ad16
|
b34654bd96750be62556ed368ef4db1043521ff2
|
/tc_bulletin/tags/version-2.0.0.1/src/java/tests/com/topcoder/messaging/AllTests.java
|
5c8119bf69735ebf9f3af06ea61b417db52c068f
|
[] |
no_license
|
topcoder-platform/tcs-cronos
|
81fed1e4f19ef60cdc5e5632084695d67275c415
|
c4ad087bb56bdaa19f9890e6580fcc5a3121b6c6
|
refs/heads/master
| 2023-08-03T22:21:52.216762
| 2019-03-19T08:53:31
| 2019-03-19T08:53:31
| 89,589,444
| 0
| 1
| null | 2019-03-19T08:53:32
| 2017-04-27T11:19:01
| null |
UTF-8
|
Java
| false
| false
| 874
|
java
|
/*
* Copyright (C) 2008 TopCoder Inc., All Rights Reserved.
*/
package com.topcoder.messaging;
import com.topcoder.messaging.accuracytests.AccuracyTests;
import com.topcoder.messaging.persistence.failuretests.FailureTests;
import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;
/**
* <p>
* This test case aggregates all the test cases.
* </p>
*
* @author yqw
* @version 1.0
*/
public class AllTests extends TestCase {
/**
* <p>
* Returns all Unit test cases.
* </p>
*
* @return all Unit test cases.
*/
public static Test suite() {
final TestSuite suite = new TestSuite();
suite.addTest(UnitTests.suite());
suite.addTest(FailureTests.suite());
suite.addTest(AccuracyTests.suite());
return suite;
}
}
|
[
"tingyifang@fb370eea-3af6-4597-97f7-f7400a59c12a"
] |
tingyifang@fb370eea-3af6-4597-97f7-f7400a59c12a
|
b6e46e0f944bfba6f25af2eb2af2108ce05ab065
|
7e57d5da0198e03c5bc9c087f891c427e2b8f42e
|
/trunk/proj/CoreLibrary/src/com/jasonzqshen/familyaccounting/core/listeners/LoadDocumentListener.java
|
bb4d5a5da62a02b2d6cf4e0236ce34df0016d3d6
|
[] |
no_license
|
BGCX067/family-accounting-svn-to-git
|
313854a60f3e9822a40e2aa09afa45109f3fa86b
|
c5a4683d603bcbcd390c042cd630512bf6c77bdd
|
refs/heads/master
| 2021-01-13T00:56:29.236695
| 2015-12-28T14:33:34
| 2015-12-28T14:33:34
| 48,875,380
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 242
|
java
|
package com.jasonzqshen.familyaccounting.core.listeners;
import com.jasonzqshen.familyaccounting.core.transaction.HeadEntity;
public interface LoadDocumentListener{
void onLoadDocumentListener(Object source, HeadEntity document);
}
|
[
"you@example.com"
] |
you@example.com
|
e2b1e52bf2c8490ae2582143f15a61bcc2dd44dc
|
59cb740d87d536b884c9f608ee5aab1868d3f983
|
/EaseUIT/src/com/easemob/easeui/widget/EaseRoundImageViewSize.java
|
5192676a93e86800d2851c7d5584b21667e0ad11
|
[
"Apache-2.0"
] |
permissive
|
HuaZhongAndroid/HanShan
|
ccb42415470b92a2922184875a85ce560addff18
|
9e465279bf1664c3fed7508640bccbe47db96b70
|
refs/heads/master
| 2021-07-08T03:20:33.223875
| 2018-12-28T13:13:57
| 2018-12-28T13:13:57
| 134,651,375
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,782
|
java
|
package com.easemob.easeui.widget;
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.graphics.PorterDuff;
import android.graphics.PorterDuffXfermode;
import android.graphics.RectF;
import android.util.AttributeSet;
import android.widget.ImageView;
/**
* 圆角ImageView
*
*
*/
public class EaseRoundImageViewSize extends ImageView {
public EaseRoundImageViewSize(Context context, AttributeSet attrs) {
super(context, attrs);
init();
}
public EaseRoundImageViewSize(Context context) {
super(context);
init();
}
private final RectF roundRect = new RectF();
private float rect_adius = 50;
private final Paint maskPaint = new Paint();
private final Paint zonePaint = new Paint();
private void init() {
maskPaint.setAntiAlias(true);
maskPaint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN));
//
zonePaint.setAntiAlias(true);
zonePaint.setColor(Color.WHITE);
//
float density = getResources().getDisplayMetrics().density;
rect_adius = rect_adius * density;
}
public void setRectAdius(float adius) {
rect_adius = adius;
invalidate();
}
@Override
protected void onLayout(boolean changed, int left, int top, int right,
int bottom) {
super.onLayout(changed, left, top, right, bottom);
int w = getWidth();
int h = getHeight();
roundRect.set(0, 0, w, h);
}
@Override
public void draw(Canvas canvas) {
canvas.saveLayer(roundRect, zonePaint, Canvas.ALL_SAVE_FLAG);
canvas.drawRoundRect(roundRect, rect_adius, rect_adius, zonePaint);
//
canvas.saveLayer(roundRect, maskPaint, Canvas.ALL_SAVE_FLAG);
super.draw(canvas);
canvas.restore();
}
}
|
[
"376368673@qq.com"
] |
376368673@qq.com
|
f1ee0d82bf3fc258f4d1bf7f28108bc29e3526e1
|
a9a7833a6b07df3877a564ff053df95c3fa2ec2f
|
/ProjectSource/src/test/java/com/kayako/sdk/error/response/LogListParserTest.java
|
c5b079032f4d60ce56e2e108a444fea618f44c07
|
[] |
no_license
|
syatanic/kayako-Kayako-Java-SDK
|
ec9b88637194a1ac934e665814600eece9fc5853
|
02b1978c5a23da71ed80986590d83587a8406ab6
|
refs/heads/master
| 2020-12-04T20:25:53.374250
| 2018-02-19T12:38:31
| 2018-02-19T12:38:31
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,285
|
java
|
package com.kayako.sdk.error.response;
import org.junit.Test;
import java.util.List;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;
/**
* @author Neil Mathew (neil.mathew@kayako.com)
* @date 05/11/16
*/
public class LogListParserTest {
// Test case that contains both errors and notifications and logs
private final String jsonWithOtherResponseMessages = "{\n" +
" \"status\": 403,\n" +
" \"errors\": [\n" +
" {\n" +
" \"code\": \"OTP_EXPECTED\",\n" +
" \"message\": \"To complete authentication you need to provide the one-time password\",\n" +
" \"moreInfo\": \"https://developer.kayako.com/api/v1/reference/errors/OTP_EXPECTED\"\n" +
" }\n" +
" ],\n" +
" \"logs\": [\n" +
" {\n" +
" \"level\": \"ERROR\",\n" +
" \"message\": \"Unhandled exception caught: Novo\\\\Library\\\\Exception\\\\InvalidArgument in __src/library/REST/Resource/Assembler/Assembler.php:423\"\n" +
" }\n" +
" ],\n" +
" \"notifications\": [\n" +
" {\n" +
" \"type\": \"INFO\",\n" +
" \"message\": \"Two-factor authentication is enabled for your account\"\n" +
" }\n" +
" ],\n" +
" \"auth_token\": \"dPQBJfPG5cGYd6MMPtowGz93x3uSN7Vc7yBw3JrKL5owqfowKFda4mezGefo5QDmRnxyV2\"\n" +
"}";
@Test
public void parseJson_alongWithLogAndNotification() throws Exception {
LogListParser logListParser = new LogListParser();
List<Log> logs = logListParser.parseList(jsonWithOtherResponseMessages);
assertTrue("Only one log", logs.size() == 1);
Log log = logs.get(0);
validateLog(log);
}
private void validateLog(Log log) {
assertNotNull(log.message);
assertNotNull(log.level);
log.level.equals("ERROR");
log.message.equals("Unhandled exception caught: Novo\\\\Library\\\\Exception\\\\InvalidArgument in __src/library/REST/Resource/Assembler/Assembler.php:423");
}
}
|
[
"mathew.neil@gmail.com"
] |
mathew.neil@gmail.com
|
2a7670b54c4b8dd380fb9903c063d6071bc9bc22
|
c2b460467bfc157c60c62fbeab359925a6b71ade
|
/procSrc/src/main/java/com/tiza/process/common/protocol/m2/cmd/CMD_88.java
|
8be6518d43633df2861152ed8c1f038645f7680a
|
[] |
no_license
|
diyiliu/PubCloud
|
13d86aa1d1ce7dc48d88859a9f609935a5800b5b
|
1440f245faaf6f27ef55dd18ad10ac8aa7c162f4
|
refs/heads/master
| 2021-01-19T14:45:31.980789
| 2017-08-21T07:07:41
| 2017-08-21T07:07:41
| 100,920,274
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,328
|
java
|
package com.tiza.process.common.protocol.m2.cmd;
import com.tiza.process.common.bean.Header;
import com.tiza.process.common.bean.M2Header;
import com.tiza.process.common.protocol.m2.M2DataProcess;
import com.tiza.process.common.util.CommonUtil;
import io.netty.buffer.ByteBuf;
import io.netty.buffer.Unpooled;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
/**
* Description: CMD_88
* Author: DIYILIU
* Update: 2017-08-03 19:15
*/
@Service
public class CMD_88 extends M2DataProcess {
public CMD_88() {
this.cmd = 0x88;
}
@Override
public void parse(byte[] content, Header header) {
M2Header m2Header = (M2Header) header;
ByteBuf buf = Unpooled.copiedBuffer(content);
// 年月日
byte[] ymd = new byte[3];
buf.readBytes(ymd);
List<Date> dateList = new ArrayList<>();
int count = buf.readByte();
// 时分秒
byte[] hms = new byte[3];
for (int i = 0; i < count; i++){
buf.readBytes(hms);
// 拼接 年月日 + 时分秒 = 完整日期
ByteBuf dateBuf = Unpooled.copiedBuffer(ymd, hms);
Date date = CommonUtil.bytesToDate(dateBuf.array());
dateList.add(date);
}
}
}
|
[
"572772828@qq.com"
] |
572772828@qq.com
|
5e6cd28f8d07578a70ffa0d865e8a219f2e3e9d8
|
a0cd546101594e679544d24f92ae8fcc17013142
|
/refactorit-core/src/test/projects/PullUpTests/Pull53/out/p1/Class1.java
|
36b8ab15bddf7df0a5b07a76ffc7113764a8b326
|
[] |
no_license
|
svn2github/RefactorIT
|
f65198bb64f6c11e20d35ace5f9563d781b7fe5c
|
4b1fc1ebd06c8e192af9ccd94eb5c2d96f79f94c
|
refs/heads/master
| 2021-01-10T03:09:28.310366
| 2008-09-18T10:17:56
| 2008-09-18T10:17:56
| 47,540,746
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 200
|
java
|
package p1;
interface InterFace1 {
// comment1
// comment2
/* comment3
comment3*/
int a = 1;
}
public class Class1 {
}
class Class2 implements InterFace1 {
int b;
int c;
}
|
[
"l950637@285b47d1-db48-0410-a9c5-fb61d244d46c"
] |
l950637@285b47d1-db48-0410-a9c5-fb61d244d46c
|
2521b54eab3d5eb75eb48b95c7b9497050430353
|
6500848c3661afda83a024f9792bc6e2e8e8a14e
|
/output/com.google.android.finsky.api.a.bm.java
|
2aab6d851301a2dc77a306432b902ee6dbb712f4
|
[] |
no_license
|
enaawy/gproject
|
fd71d3adb3784d12c52daf4eecd4b2cb5c81a032
|
91cb88559c60ac741d4418658d0416f26722e789
|
refs/heads/master
| 2021-09-03T03:49:37.813805
| 2018-01-05T09:35:06
| 2018-01-05T09:35:06
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 383
|
java
|
package com.google.android.finsky.api.a;
import com.google.protobuf.nano.i;
import com.google.wireless.android.finsky.dfe.nano.fk;
public final class com.google.android.finsky.api.a.bm implements com.google.android.finsky.api.a.cz
{
bm() {
}
public final com.google.protobuf.nano.i a(com.google.wireless.android.finsky.dfe.nano.fk p0) {
return p0.e;
}
}
|
[
"genius.ron@gmail.com"
] |
genius.ron@gmail.com
|
3e77f34a764f093419f11a5e272087e35402f253
|
bf7964769d780ad1b729be0434ac6d5108fba3d0
|
/src/api/com/gsma/services/rcs/chat/ChatMessage.java
|
8dde7fbe3ad29d1ac4495ec8f9f066d690a345d5
|
[
"Apache-2.0"
] |
permissive
|
hl4/rcscore
|
4100cbf3a63a4d8c49cac68245a8c8c70cb63834
|
b4e2896fe65f26defc272aa5b394aa9441bcab78
|
refs/heads/master
| 2021-01-20T17:26:48.029669
| 2016-04-19T13:02:39
| 2016-04-19T13:02:39
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 5,997
|
java
|
/*******************************************************************************
* Software Name : RCS IMS Stack
*
* Copyright (C) 2010 France Telecom S.A.
* Copyright (C) 2014 Sony Mobile Communications Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* NOTE: This file has been modified by Sony Mobile Communications Inc.
* Modifications are licensed under the License.
******************************************************************************/
package com.gsma.services.rcs.chat;
import com.gsma.services.rcs.RcsServiceException;
import com.gsma.services.rcs.contacts.ContactId;
/**
* Chat message
*
* @author Jean-Marc AUFFRET
* @author YPLO6403
*/
public class ChatMessage {
private final IChatMessage mChatMessageInf;
/**
* Constructor
*
* @param chatMessageInf IChatMessage
*/
/* package private */ChatMessage(IChatMessage chatMessageInf) {
mChatMessageInf = chatMessageInf;
}
/**
* Returns the message ID
*
* @return ID
* @throws RcsServiceException
*/
public String getId() throws RcsServiceException {
try {
return mChatMessageInf.getId();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the contact
*
* @return ContactId
* @throws RcsServiceException
*/
public ContactId getRemoteContact() throws RcsServiceException {
try {
return mChatMessageInf.getContact();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the message content
*
* @return String
* @throws RcsServiceException
*/
public String getContent() throws RcsServiceException {
try {
return mChatMessageInf.getContent();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the mime type of the chat message.
*
* @return ContactId
* @throws RcsServiceException
*/
public String getMimeType() throws RcsServiceException {
try {
return mChatMessageInf.getMimeType();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the direction of message (incoming or outgoing)
*
* @return Direction
* @see com.gsma.services.rcs.RcsCommon.Direction
* @throws RcsServiceException
*/
public int getDirection() throws RcsServiceException {
try {
return mChatMessageInf.getDirection();
} catch(Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the local time-stamp of when the chat message was sent and/or
* queued for outgoing messages or the local time-stamp of when the chat
* message was received for incoming messages.
*
* @return long
* @throws RcsServiceException
*/
public long getTimestamp() throws RcsServiceException {
try {
return mChatMessageInf.getTimestamp();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the local time-stamp of when the chat message was sent and/or
* queued for outgoing messages or the remote time-stamp of when the chat
* message was sent for incoming messages.
*
* @return long
* @throws RcsServiceException
*/
public long getTimestampSent() throws RcsServiceException {
try {
return mChatMessageInf.getTimestampSent();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the local timestamp of when the chat message was delivered for
* outgoing messages or 0 for incoming messages or it was not yet delivered.
*
* @return long
* @throws RcsServiceException
*/
public long getTimestampDelivered() throws RcsServiceException {
try {
return mChatMessageInf.getTimestampDelivered();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the local timestamp of when the chat message was displayed for
* outgoing messages or 0 for incoming messages or it was not yes displayed.
*
* @return long
* @throws RcsServiceException
*/
public long getTimestampDisplayed() throws RcsServiceException {
try {
return mChatMessageInf.getTimestampDisplayed();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the status of the chat message.
*
* @return Status
* @throws RcsServiceException
*/
public int getStatus() throws RcsServiceException {
try {
return mChatMessageInf.getStatus();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the reason code of the chat message.
*
* @return ReasonCode
* @throws RcsServiceException
*/
public int getReasonCode() throws RcsServiceException {
try {
return mChatMessageInf.getReasonCode();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns the chat ID of this chat message.
*
* @return String
* @throws RcsServiceException
*/
public String getChatId() throws RcsServiceException {
try {
return mChatMessageInf.getChatId();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
/**
* Returns true is this chat message has been marked as read.
*
* @return boolean
* @throws RcsServiceException
*/
public boolean isRead() throws RcsServiceException {
try {
return mChatMessageInf.isRead();
} catch (Exception e) {
throw new RcsServiceException(e.getMessage());
}
}
}
|
[
"ah@lilizhendeMacBook.local"
] |
ah@lilizhendeMacBook.local
|
ed3dc2f6c5f62020ef7b36f5affea402902e5139
|
043703eaf27a0d5e6f02bf7a9ac03c0ce4b38d04
|
/subject_systems/Struts2/src/struts-2.5.10.1/src/plugins/rest/src/main/java/org/apache/struts2/rest/ContentTypeHandlerManager.java
|
f6b1b31424752dea63b8cdee15099b966995300d
|
[] |
no_license
|
MarceloLaser/arcade_console_test_resources
|
e4fb5ac4a7b2d873aa9d843403569d9260d380e0
|
31447aabd735514650e6b2d1a3fbaf86e78242fc
|
refs/heads/master
| 2020-09-22T08:00:42.216653
| 2019-12-01T21:51:05
| 2019-12-01T21:51:05
| 225,093,382
| 1
| 2
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 129
|
java
|
version https://git-lfs.github.com/spec/v1
oid sha256:5c11086427a1bc31872bac07bebc013892f2f08c2bdef4b7acdcb5609410de2d
size 2594
|
[
"marcelo.laser@gmail.com"
] |
marcelo.laser@gmail.com
|
f1b7ce16c3d1debb053c806752a5fcd8ebcf8f3e
|
86ba5bc2010a0c044c84b68658cc15606152fc4d
|
/v-customview/src/main/java/com/vension/customview/timepicker/ScreenUtil.java
|
e364006ea76ddb59c9ad2b7cec72e7bcb2bf1c9f
|
[
"Apache-2.0"
] |
permissive
|
Vension/KV-Frame
|
8e8433b85f62c5768549358db6d988033f5c2f3e
|
878f17d8ab80f61437adc770015ec72b27279b3b
|
refs/heads/master
| 2021-04-18T18:38:31.284240
| 2018-05-23T02:35:29
| 2018-05-23T02:35:29
| 126,779,607
| 8
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 906
|
java
|
package com.vension.customview.timepicker;
import android.content.Context;
import android.util.DisplayMetrics;
import android.view.WindowManager;
/**
* Created by liuli on 2015/11/27.
*/
public class ScreenUtil {
public static int height;
public static int width;
private Context context;
private static ScreenUtil instance;
private ScreenUtil(Context context) {
this.context = context;
WindowManager manager = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE);
DisplayMetrics dm = new DisplayMetrics();
manager.getDefaultDisplay().getMetrics(dm);
width = dm.widthPixels;
height = dm.heightPixels;
}
public static ScreenUtil getInstance(Context context) {
if (instance == null) {
instance = new ScreenUtil(context);
}
return instance;
}
/**
* 得到手机屏幕的宽度, pix单位
*/
public int getScreenWidth() {
return width;
}
}
|
[
"hqw@kewaimiao.com"
] |
hqw@kewaimiao.com
|
6520efb1b38c7125431844e7cfc83d9e3eb0218a
|
7ce370b237e933871e9d1c24aabe674e8e26659b
|
/project/giving-batch/src/generated/com/virginmoneygiving/paymentmanagement/service/messages/UpdateGiftAidClaimForSettlementResponse.java
|
a47e889444049dc13f4633c3b948d1efb59689c0
|
[] |
no_license
|
ankurmitujjain/virginmoney
|
16c21fb7ba03b70f8fab02f6543e6531c275cfab
|
2355ea70b25ac00c212f8968f072365a53ef0cbc
|
refs/heads/master
| 2020-12-31T04:42:42.191330
| 2009-09-18T06:40:02
| 2009-09-18T06:40:02
| 57,319,348
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,495
|
java
|
package com.virginmoneygiving.paymentmanagement.service.messages;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;
/**
* <p>Java class for anonymous complex type.
*
* <p>The following schema fragment specifies the expected content contained within this class.
*
* <pre>
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <element name="statusUpdated" type="{http://www.w3.org/2001/XMLSchema}boolean"/>
* <element name="basicReponse" type="{http://www.virginmoneygiving.com/type/payment-management/common/}BasicResponse"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
"statusUpdated",
"basicReponse"
})
@XmlRootElement(name = "updateGiftAidClaimForSettlementResponse", namespace = "http://www.virginmoneygiving.com/type/payment-management/operations/")
public class UpdateGiftAidClaimForSettlementResponse {
@XmlElement(namespace = "http://www.virginmoneygiving.com/type/payment-management/operations/")
protected boolean statusUpdated;
@XmlElement(namespace = "http://www.virginmoneygiving.com/type/payment-management/operations/", required = true)
protected BasicResponse basicReponse;
/**
* Gets the value of the statusUpdated property.
*
*/
public boolean isStatusUpdated() {
return statusUpdated;
}
/**
* Sets the value of the statusUpdated property.
*
*/
public void setStatusUpdated(boolean value) {
this.statusUpdated = value;
}
/**
* Gets the value of the basicReponse property.
*
* @return
* possible object is
* {@link BasicResponse }
*
*/
public BasicResponse getBasicReponse() {
return basicReponse;
}
/**
* Sets the value of the basicReponse property.
*
* @param value
* allowed object is
* {@link BasicResponse }
*
*/
public void setBasicReponse(BasicResponse value) {
this.basicReponse = value;
}
}
|
[
"ankurmitujjain@60e5a148-1378-11de-b480-edb48bd02f47"
] |
ankurmitujjain@60e5a148-1378-11de-b480-edb48bd02f47
|
541a52864cc03e68a774dd8b96fe69fb144819e9
|
adad299298b3a4ddbc0d152093b3e5673a940e52
|
/2018/neohort-xlsx-poi/src/main/java/neohort/universal/output/lib_xlsx/page_footer_.java
|
340e6fbf3d97304715b26213a7eac3c1b7672c09
|
[] |
no_license
|
surban1974/neohort
|
a692e49c8e152cea0b155d81c2b2b1b167630ba8
|
0c371590e739defbc25d5befd1d44fcf18d1bcab
|
refs/heads/master
| 2022-07-27T18:57:49.916560
| 2022-01-04T18:00:12
| 2022-01-04T18:00:12
| 5,521,942
| 2
| 1
| null | 2022-06-30T20:10:02
| 2012-08-23T08:33:40
|
Java
|
UTF-8
|
Java
| false
| false
| 1,911
|
java
|
/**
* Creation date: (22/12/2005)
* @author: Svyatoslav Urbanovych surban@bigmir.net svyatoslav.urbanovych@gmail.com
*/
/********************************************************************************
*
* Copyright (C) 2005 Svyatoslav Urbanovych
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*********************************************************************************/
package neohort.universal.output.lib_xlsx;
import java.util.Hashtable;
import neohort.log.stubs.iStub;
import neohort.universal.output.lib.report_element_base;
public class page_footer_ extends element{
private static final long serialVersionUID = -1L;
public page_footer_() {
super();
}
public void executeFirst(Hashtable<String, report_element_base> _tagLibrary, Hashtable<String, report_element_base> _beanLibrary){
}
public void executeLast(Hashtable<String, report_element_base> _tagLibrary, Hashtable<String, report_element_base> _beanLibrary){
try{
if(_tagLibrary.get(getName()+":"+getID())==null)
_tagLibrary.remove(getName()+":"+getID()+"_ids_"+this.motore.hashCode());
else _tagLibrary.remove(getName()+":"+getID());
}catch(Exception e){
setError(e,iStub.log_WARN);
}
}
public void reimposta() {
setName("PAGE_FOOTER_");
STYLE_ID = "";
}
}
|
[
"svyatoslav.urbanovych@gmail.com"
] |
svyatoslav.urbanovych@gmail.com
|
2384709b9fe3b75abca71514bf648028f8774c7c
|
fce50ff46280a121d0c0ab47331c18d004ea94b7
|
/app/src/main/java/sembako/sayunara/android/ui/component/product/detailproduct/widget/WrapContentViewPager.java
|
77f387450957a302cdebaaeb847c21c9659aaf7a
|
[] |
no_license
|
asywalulfikri/chongsengnim
|
dda6ab380579451f83f67c488b25642c0d39fb86
|
c034b861eae15ad24d169b6ee58800864e8a3c92
|
refs/heads/master
| 2023-04-09T01:25:32.827155
| 2023-04-03T09:49:18
| 2023-04-03T09:49:18
| 215,968,985
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,613
|
java
|
package sembako.sayunara.android.ui.component.product.detailproduct.widget;
import android.content.Context;
import android.util.AttributeSet;
import android.view.View;
import androidx.viewpager.widget.ViewPager;
public class WrapContentViewPager extends ViewPager {
public WrapContentViewPager(Context context) {
super(context);
}
public WrapContentViewPager(Context context, AttributeSet attrs) {
super(context, attrs);
}
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
int mode = MeasureSpec.getMode(heightMeasureSpec);
// Unspecified means that the ViewPager is in a ScrollView WRAP_CONTENT.
// At Most means that the ViewPager is not in a ScrollView WRAP_CONTENT.
if (mode == MeasureSpec.UNSPECIFIED || mode == MeasureSpec.AT_MOST) {
// super has to be called in the beginning so the child views can be initialized.
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
int height = 0;
for (int i = 0; i < getChildCount(); i++) {
View child = getChildAt(i);
child.measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(0, MeasureSpec.UNSPECIFIED));
int h = child.getMeasuredHeight();
if (h > height) height = h;
}
heightMeasureSpec = MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY);
}
// super has to be called again so the new specs are treated as exact measurements
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
}
}
|
[
"asywalulfikri@yahoo.co.id"
] |
asywalulfikri@yahoo.co.id
|
de30f92246a763a9962940a9d4c9f9a965dea71a
|
5ce4df54c97e1701cf4417d31c311dc3b200a369
|
/app/src/main/java/com/wxx/shopping/moudle/mine/MineFragment.java
|
b3ae86700ac39b67c4cd6fa5b7aaab1cf9052913
|
[] |
no_license
|
dingxiaojiao/Shopping
|
e4ffa375c99b62a280bcd1692873bbab29f27c06
|
50cfd5ae25713b8a4709486fde55425d5011fd1f
|
refs/heads/master
| 2021-01-22T20:28:56.891819
| 2017-03-17T12:55:31
| 2017-03-17T12:55:31
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 811
|
java
|
package com.wxx.shopping.moudle.mine;
import android.os.Bundle;
import com.wxx.shopping.base.BaseFragment;
import com.wxx.shopping.base.BasePresenter;
/**
* 作者:Tangren_ on 2017/3/15 21:25.
* 邮箱:wu_tangren@163.com
* TODO:一句话描述
*/
public class MineFragment extends BaseFragment {
public static MineFragment newInstance() {
Bundle args = new Bundle();
MineFragment fragment = new MineFragment();
fragment.setArguments(args);
return fragment;
}
@Override
protected BasePresenter createPresenter() {
return null;
}
@Override
protected void initView(Bundle savedInstanceState) {
}
@Override
protected int initLayout() {
return 0;
}
@Override
protected void initData() {
}
}
|
[
"996489865@qq.com"
] |
996489865@qq.com
|
69731e4ed0fb7a28b1f8d48cdca604d8ca12d7d7
|
689cdf772da9f871beee7099ab21cd244005bfb2
|
/classes/com/tencent/av/opengl/gesturedetectors/ShoveGestureDetector$SimpleOnShoveGestureListener.java
|
4c7470910e9e664005ccdaccb4d07959906900e5
|
[] |
no_license
|
waterwitness/dazhihui
|
9353fd5e22821cb5026921ce22d02ca53af381dc
|
ad1f5a966ddd92bc2ac8c886eb2060d20cf610b3
|
refs/heads/master
| 2020-05-29T08:54:50.751842
| 2016-10-08T08:09:46
| 2016-10-08T08:09:46
| 70,314,359
| 2
| 4
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 688
|
java
|
package com.tencent.av.opengl.gesturedetectors;
public class ShoveGestureDetector$SimpleOnShoveGestureListener
implements ShoveGestureDetector.OnShoveGestureListener
{
public boolean onShove(ShoveGestureDetector paramShoveGestureDetector)
{
return false;
}
public boolean onShoveBegin(ShoveGestureDetector paramShoveGestureDetector)
{
return true;
}
public void onShoveEnd(ShoveGestureDetector paramShoveGestureDetector) {}
}
/* Location: E:\apk\dazhihui2\classes-dex2jar.jar!\com\tencent\av\opengl\gesturedetectors\ShoveGestureDetector$SimpleOnShoveGestureListener.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/
|
[
"1776098770@qq.com"
] |
1776098770@qq.com
|
93c855f5c2d849683f5de20d7c7cd93fd6c79694
|
5e3235edf3de262f4d10b9e9e1fcc3bd13d6b8b1
|
/Code Snippet Repository/Junit/Junit875.java
|
bd81d1a4cc92726bb045dd41d19837bb28b8ee29
|
[] |
no_license
|
saber13812002/DeepCRM
|
3336a244d4852a364800af3181e03e868cf6f9f5
|
be3e5e50e34a042d5ba7259ff5ff75c08ab32bb9
|
refs/heads/master
| 2023-03-16T00:08:06.473699
| 2018-04-18T05:29:50
| 2018-04-18T05:29:50
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 355
|
java
|
@SuppressWarnings("")
@Test
void toStreamWithIterable() {
Iterable<String> input = new Iterable<String>() {
@Override
public Iterator<String> iterator() {
return asList("foo", "bar").iterator();
}
};
Stream<String> result = (Stream<String>) CollectionUtils.toStream(input);
assertThat(result).containsExactly("foo", "bar");
}
|
[
"Qing.Mi@my.cityu.edu.hk"
] |
Qing.Mi@my.cityu.edu.hk
|
b326eaf2ae1da61d8b528c0f9dbb4db3e7965467
|
41ce5edf2e270e321dddd409ffac11ab7f32de86
|
/8/android/media/CamcorderProfile.java
|
64d6460dbd6857f08eb980c643a7f366a061ef4a
|
[] |
no_license
|
danny-source/SDK_Android_Source_03-14
|
372bb03020203dba71bc165c8370b91c80bc6eaa
|
323ad23e16f598d5589485b467bb9fba7403c811
|
refs/heads/master
| 2020-05-18T11:19:29.171830
| 2014-03-29T12:12:44
| 2014-03-29T12:12:44
| 18,238,039
| 2
| 2
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 5,419
|
java
|
/*
* Copyright (C) 2010 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.media;
/**
* The CamcorderProfile class is used to retrieve the
* predefined camcorder profile settings for camcorder applications.
* These settings are read-only.
*
* The compressed output from a recording session with a given
* CamcorderProfile contains two tracks: one for auido and one for video.
*
* <p>Each profile specifies the following set of parameters:
* <ul>
* <li> The file output format
* <li> Video codec format
* <li> Video bit rate in bits per second
* <li> Video frame rate in frames per second
* <li> Video frame width and height,
* <li> Audio codec format
* <li> Audio bit rate in bits per second,
* <li> Audio sample rate
* <li> Number of audio channels for recording.
* </ul>
*/
public class CamcorderProfile
{
/**
* The output from camcorder recording sessions can have different quality levels.
*
* Currently, we define two quality levels: high quality and low quality.
* A camcorder recording session with high quality level usually has higher output bit
* rate, better video and/or audio recording quality, larger video frame
* resolution and higher audio sampling rate, etc, than those with low quality
* level.
*
* Do not change these values/ordinals without updating their counterpart
* in include/media/MediaProfiles.h!
*/
public static final int QUALITY_LOW = 0;
public static final int QUALITY_HIGH = 1;
/**
* Default recording duration in seconds before the session is terminated.
* This is useful for applications like MMS has limited file size requirement.
*/
public int duration;
/**
* The quality level of the camcorder profile
*/
public int quality;
/**
* The file output format of the camcorder profile
* @see android.media.MediaRecorder.OutputFormat
*/
public int fileFormat;
/**
* The video encoder being used for the video track
* @see android.media.MediaRecorder.VideoEncoder
*/
public int videoCodec;
/**
* The target video output bit rate in bits per second
*/
public int videoBitRate;
/**
* The target video frame rate in frames per second
*/
public int videoFrameRate;
/**
* The target video frame width in pixels
*/
public int videoFrameWidth;
/**
* The target video frame height in pixels
*/
public int videoFrameHeight;
/**
* The audio encoder being used for the audio track.
* @see android.media.MediaRecorder.AudioEncoder
*/
public int audioCodec;
/**
* The target audio output bit rate in bits per second
*/
public int audioBitRate;
/**
* The audio sampling rate used for the audio track
*/
public int audioSampleRate;
/**
* The number of audio channels used for the audio track
*/
public int audioChannels;
/**
* Returns the camcorder profile for the given quality level.
* @param quality the target quality level for the camcorder profile
*/
public static CamcorderProfile get(int quality) {
if (quality < QUALITY_LOW || quality > QUALITY_HIGH) {
String errMessage = "Unsupported quality level: " + quality;
throw new IllegalArgumentException(errMessage);
}
return native_get_camcorder_profile(quality);
}
static {
System.loadLibrary("media_jni");
native_init();
}
// Private constructor called by JNI
private CamcorderProfile(int duration,
int quality,
int fileFormat,
int videoCodec,
int videoBitRate,
int videoFrameRate,
int videoWidth,
int videoHeight,
int audioCodec,
int audioBitRate,
int audioSampleRate,
int audioChannels) {
this.duration = duration;
this.quality = quality;
this.fileFormat = fileFormat;
this.videoCodec = videoCodec;
this.videoBitRate = videoBitRate;
this.videoFrameRate = videoFrameRate;
this.videoFrameWidth = videoWidth;
this.videoFrameHeight = videoHeight;
this.audioCodec = audioCodec;
this.audioBitRate = audioBitRate;
this.audioSampleRate = audioSampleRate;
this.audioChannels = audioChannels;
}
// Methods implemented by JNI
private static native final void native_init();
private static native final CamcorderProfile native_get_camcorder_profile(int quality);
}
|
[
"danny@35g.tw"
] |
danny@35g.tw
|
4a73c3cf022edd94bc00ff73946f35fa1ece4829
|
56f59f6bca7b0e7b08fdf827b18a03648b3453b1
|
/codegenerator/src/main/java/com/thanos/contract/codegenerator/infrastructure/dto/ContractFileDTO.java
|
ac4bf37d1f3b862c3ba73dd7f6bf868d063835cf
|
[
"MIT"
] |
permissive
|
fossabot/ThanosContract
|
f71c4fdd5ad821d165d5f1a61dffe1de4230a2d8
|
a87dfe70bc27cc985df95513371890d58f840f8f
|
refs/heads/master
| 2020-12-14T19:34:49.303213
| 2020-01-19T05:58:22
| 2020-01-19T05:58:22
| 234,848,509
| 0
| 0
|
MIT
| 2020-01-19T05:58:17
| 2020-01-19T05:58:17
| null |
UTF-8
|
Java
| false
| false
| 1,702
|
java
|
package com.thanos.contract.codegenerator.infrastructure.dto;
import com.thanos.contract.codegenerator.domain.model.Contract;
import com.thanos.contract.codegenerator.domain.model.ContractField;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;
import java.util.*;
@Getter
@Setter
@NoArgsConstructor
@ToString
public class ContractFileDTO {
String name;
String version;
String consumer;
Map<String, String> schema;
LinkedHashMap<String, String> req;
LinkedHashMap<String, String> res;
public static List<Contract> buildFrom(Iterable<Object> ymlResult) {
final List<Contract> result = new ArrayList<>();
for (Object record : ymlResult) {
if (record instanceof ContractFileDTO) {
result.add(((ContractFileDTO) record).toContract());
}
}
return result;
}
public Contract toContract() {
LinkedList<ContractField> request = buildContractFieldList(req);
LinkedList<ContractField> response = buildContractFieldList(res);
String schemaIndex = schema.get("provider") + "-" + schema.get("name") + "-" + schema.get("version");
return new Contract(name, version, schemaIndex, consumer,
schema.get("provider"), request, response);
}
LinkedList<ContractField> buildContractFieldList(LinkedHashMap<String, String> originDtoMap) {
LinkedList<ContractField> result = new LinkedList<>();
for (String key : originDtoMap.keySet()) {
String content = originDtoMap.get(key);
result.add(new ContractField(key, content));
}
return result;
}
}
|
[
"abigail830@163.com"
] |
abigail830@163.com
|
bfa9cf6185c7e519f09c93e2011fe6e440e8697a
|
9d8d9e394bec2ec8486b692fe85214e9adfc5f06
|
/server/src/main/java/com/cezarykluczynski/stapi/server/common/converter/LocalDateRestParamConverterProvider.java
|
702855e3b3574d4edea0f9f1f6d9e2a267a763d0
|
[
"MIT"
] |
permissive
|
cezarykluczynski/stapi
|
a343e688c7e8ce86601c9c0a71e2445cfbd9b0b9
|
1729aae76ae161b0dff50d9124e337b67c934da0
|
refs/heads/master
| 2023-06-09T16:18:03.000465
| 2023-06-08T19:11:30
| 2023-06-08T19:11:30
| 70,270,193
| 128
| 17
|
MIT
| 2023-02-04T21:35:35
| 2016-10-07T17:55:21
|
Groovy
|
UTF-8
|
Java
| false
| false
| 674
|
java
|
package com.cezarykluczynski.stapi.server.common.converter;
import jakarta.ws.rs.ext.ParamConverter;
import jakarta.ws.rs.ext.ParamConverterProvider;
import java.lang.annotation.Annotation;
import java.lang.reflect.Type;
import java.time.LocalDate;
public class LocalDateRestParamConverterProvider implements ParamConverterProvider {
private ParamConverter<LocalDate> localDateParamConverter = new LocalDateRestParamConverter();
@Override
public <T> ParamConverter<T> getConverter(Class<T> rawType, Type genericType, Annotation[] annotations) {
if (rawType.equals(LocalDate.class)) {
return (ParamConverter<T>) localDateParamConverter;
}
return null;
}
}
|
[
"cezary.kluczynski@gmail.com"
] |
cezary.kluczynski@gmail.com
|
3e1975b1e90b328766dcf9d53a1c7c7acbe505c8
|
db6e498dd76a6ce78d83e1e7801674783230a90d
|
/thirdlib/base-protocol/protocol/src/main/java/pb4client/BuyAllianceShopOrBuilder.java
|
d265c1032c41601be14e5298ea84728bff9dc200
|
[] |
no_license
|
daxingyou/game-4
|
3d78fb460c4b18f711be0bb9b9520d3e8baf8349
|
2baef6cebf5eb0991b1f5c632c500b522c41ab20
|
refs/heads/master
| 2023-03-19T15:57:56.834881
| 2018-10-10T06:35:57
| 2018-10-10T06:35:57
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| true
| 611
|
java
|
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: client2server.proto
package pb4client;
public interface BuyAllianceShopOrBuilder extends
// @@protoc_insertion_point(interface_extends:client2server.BuyAllianceShop)
com.google.protobuf.MessageOrBuilder {
/**
* <pre>
* 要购买的物品在商店中的位置
* </pre>
*
* <code>required int32 shopAddress = 1;</code>
*/
boolean hasShopAddress();
/**
* <pre>
* 要购买的物品在商店中的位置
* </pre>
*
* <code>required int32 shopAddress = 1;</code>
*/
int getShopAddress();
}
|
[
"weiwei.witch@gmail.com"
] |
weiwei.witch@gmail.com
|
2f1a860c13d32629f363488c12aa9dd0767b14ed
|
c32e30b903e3b58454093cd8ee5c7bba7fb07365
|
/source/Class_14103.java
|
92e2b43275675242c5a83b3b1e66de4c2fe80a56
|
[] |
no_license
|
taiwan902/bp-src
|
0ee86721545a647b63848026a995ddb845a62969
|
341a34ebf43ab71bea0becf343795e241641ef6a
|
refs/heads/master
| 2020-12-20T09:17:11.506270
| 2020-01-24T15:15:30
| 2020-01-24T15:15:30
| 236,025,046
| 1
| 1
| null | 2020-01-24T15:10:30
| 2020-01-24T15:10:29
| null |
UTF-8
|
Java
| false
| false
| 5,195
|
java
|
/*
* Decompiled with CFR 0.145.
*/
import java.lang.invoke.MethodHandle;
import java.lang.invoke.MethodHandles;
import java.util.Random;
public class Class_14103
extends Class_3529 {
public static final Class_4173 Field_14104 = Class_4173.Method_4177(Class_14103.Method_14107("\u5100\u5103\u5101\u5102\u5107\u5104\u5106\u5104\u5100"));
public void Method_14105(Class_283 class_283, Class_4751 class_4751, Class_3436 class_3436, Class_3238 class_3238) {
if (!class_283.Field_306) {
boolean bl = class_283.Method_414(class_4751);
boolean bl2 = (Boolean)class_3436.Method_3440(Field_14104);
if (bl && !bl2) {
class_283.Method_462(class_4751, class_3436.Method_3437(Field_14104, Boolean.valueOf((20609 & 9729) != 0)), -19402 & 2060);
class_283.Method_441(class_4751, this, this.Method_14117(class_283));
} else if (!bl && bl2) {
class_283.Method_462(class_4751, class_3436.Method_3437(Field_14104, Boolean.valueOf((8642 & 2065) != 0)), -28523 & 26628);
}
}
}
public Class_3436 Method_14106(int n) {
return this.\u0000strictfp().Method_3685(Field_14104, Boolean.valueOf(((n & (11 & -13759)) > 0 ? 17431 & 8353 : 4628 & -29695) != 0));
}
private static String Method_14107(String string) {
int n = 22481;
char[] arrc = string.toCharArray();
StackTraceElement[] arrstackTraceElement = new Throwable().getStackTrace();
n = (char)(n ^ (char)arrstackTraceElement[0].getMethodName().hashCode());
n = (char)(n ^ (char)arrstackTraceElement[1].getMethodName().hashCode());
n = (char)(n ^ (char)arrstackTraceElement[1].getClassName().hashCode());
char c = (char)Class_8.Method_10(Class_14103.class, 1);
n = (char)(n ^ c);
char c2 = (char)(n >> 7);
for (int n2 = 0; n2 < arrc.length; n2 = (int)((char)(n2 + 1))) {
arrc[n2] = (char)(arrc[n2] ^ n ^ n2 & c2);
}
return new String(arrc);
}
public boolean Method_14108() {
return (-32249 & 18713) != 0;
}
private void Method_14109() {
MethodHandle methodHandle = MethodHandles.constant(String.class, "MC|BlazingPack");
}
public void Method_14110(Class_283 class_283, Class_4751 class_4751, Class_3436 class_3436, Class_859 class_859, Class_23823 class_23823) {
Class_4879 class_4879 = class_283.Method_429(class_4751);
if (class_4879 instanceof Class_43621) {
Class_35869 class_35869 = ((Class_43621)class_4879).Method_43628();
if (class_23823.Method_23851()) {
class_35869.Method_35882(class_23823.Method_23899());
}
if (!class_283.Field_306) {
class_35869.Method_35890(class_283.Method_522().Method_7529("sendCommandFeedback"));
}
}
}
public int Method_14111() {
return 2051 & 25615;
}
public int Method_14112(Class_3436 class_3436) {
int n = 8336 & -30430;
if (((Boolean)class_3436.Method_3440(Field_14104)).booleanValue()) {
n |= 4177 & -24571;
}
return n;
}
public Class_14103() {
super(Class_3713.Field_3748, Class_3779.Field_3813);
this.\u0000strictfp(this.\u0000strictfp.Method_3867().Method_3437(Field_14104, Boolean.valueOf((8 & 96) != 0)));
}
public void Method_14113(Class_283 class_283, Class_4751 class_4751, Class_3436 class_3436, Random random) {
Class_4879 class_4879 = class_283.Method_429(class_4751);
if (class_4879 instanceof Class_43621) {
((Class_43621)class_4879).Method_43628().Method_35891(class_283);
class_283.Method_520(class_4751, this);
}
}
public Class_4879 Method_14114(Class_283 class_283, int n) {
return new Class_43621();
}
public int Method_14115(Random random) {
return 1350 & -8160;
}
public int Method_14116(Class_283 class_283, Class_4751 class_4751) {
Class_4879 class_4879 = class_283.Method_429(class_4751);
return class_4879 instanceof Class_43621 ? ((Class_43621)class_4879).Method_43628().Method_35886() : 1046 & -13856;
}
public int Method_14117(Class_283 class_283) {
return 269 & 17921;
}
public boolean Method_14118(Class_283 class_283, Class_4751 class_4751, Class_3436 class_3436, Class_626 class_626, Class_4595 class_4595, float f, float f2, float f3) {
Class_4879 class_4879 = class_283.Method_429(class_4751);
return class_4879 instanceof Class_43621 ? ((Class_43621)class_4879).Method_43628().Method_35877(class_626) : 10560 & -11261;
}
public Class_3436 Method_14119(Class_283 class_283, Class_4751 class_4751, Class_4595 class_4595, float f, float f2, float f3, int n, Class_859 class_859) {
return this.\u0000strictfp().Method_3685(Field_14104, Boolean.valueOf((580 & 6154) != 0));
}
protected Class_3855 Method_14120() {
Class_3538[] arrclass_3538 = new Class_3538[1657 & 7];
arrclass_3538[2625 & 8458] = Field_14104;
return new Class_3855(this, arrclass_3538);
}
}
|
[
"szymex73@gmail.com"
] |
szymex73@gmail.com
|
0e3b74c7cdf404545223db911607c51b64c8f90a
|
e27942cce249f7d62b7dc8c9b86cd40391c1ddd4
|
/modules/adwords_axis/src/main/java/com/google/api/ads/adwords/axis/v201705/cm/BiddingStrategyService.java
|
7cfdfe88b707e588838e0e15b57b5d7e13a3c3b0
|
[
"Apache-2.0"
] |
permissive
|
mo4ss/googleads-java-lib
|
b4b6178747d25d16ae6aa0c80d80ee18a2dfe01a
|
efaa9c3bd8a46a3ed4b00963dc9760c6dd8bd641
|
refs/heads/master
| 2022-12-05T00:30:56.740813
| 2022-11-16T10:47:15
| 2022-11-16T10:47:15
| 108,132,394
| 0
| 0
|
Apache-2.0
| 2022-11-16T10:47:16
| 2017-10-24T13:41:43
|
Java
|
UTF-8
|
Java
| false
| false
| 1,326
|
java
|
// Copyright 2017 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
/**
* BiddingStrategyService.java
*
* This file was auto-generated from WSDL
* by the Apache Axis 1.4 Mar 02, 2009 (07:08:06 PST) WSDL2Java emitter.
*/
package com.google.api.ads.adwords.axis.v201705.cm;
public interface BiddingStrategyService extends javax.xml.rpc.Service {
public java.lang.String getBiddingStrategyServiceInterfacePortAddress();
public com.google.api.ads.adwords.axis.v201705.cm.BiddingStrategyServiceInterface getBiddingStrategyServiceInterfacePort() throws javax.xml.rpc.ServiceException;
public com.google.api.ads.adwords.axis.v201705.cm.BiddingStrategyServiceInterface getBiddingStrategyServiceInterfacePort(java.net.URL portAddress) throws javax.xml.rpc.ServiceException;
}
|
[
"jradcliff@users.noreply.github.com"
] |
jradcliff@users.noreply.github.com
|
df8b53317e8c81df920b8d6149a60802caf87169
|
e1fd6855c11612e3506ba9b569c49a3843264996
|
/projects/OG-Financial/src/com/opengamma/financial/analytics/model/horizon/ForexForwardConstantSpreadThetaFunction.java
|
0e55ee39ba663060809bca12127e537426f2d5ba
|
[
"Apache-2.0"
] |
permissive
|
garykennedy/OG-Platform
|
8daaf382653a889c87b284921878b2ef69e19c04
|
0230f7d9b0adff1d7c68a5f968ad929e29cd3d63
|
refs/heads/master
| 2020-12-25T09:37:32.009500
| 2012-12-16T17:54:27
| 2012-12-16T17:54:27
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 6,548
|
java
|
/**
* Copyright (C) 2012 - present by OpenGamma Inc. and the OpenGamma group of companies
*
* Please see distribution for license.
*/
package com.opengamma.financial.analytics.model.horizon;
import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
import java.util.Set;
import javax.time.calendar.Clock;
import javax.time.calendar.ZonedDateTime;
import org.apache.commons.lang.NotImplementedException;
import com.opengamma.analytics.financial.forex.definition.ForexDefinition;
import com.opengamma.analytics.financial.forex.derivative.Forex;
import com.opengamma.analytics.financial.interestrate.ConstantSpreadHorizonThetaCalculator;
import com.opengamma.analytics.financial.interestrate.YieldCurveBundle;
import com.opengamma.analytics.financial.model.interestrate.curve.YieldAndDiscountCurve;
import com.opengamma.engine.ComputationTarget;
import com.opengamma.engine.function.FunctionExecutionContext;
import com.opengamma.engine.function.FunctionInputs;
import com.opengamma.engine.value.ComputedValue;
import com.opengamma.engine.value.ValueProperties;
import com.opengamma.engine.value.ValuePropertyNames;
import com.opengamma.engine.value.ValueRequirement;
import com.opengamma.engine.value.ValueRequirementNames;
import com.opengamma.engine.value.ValueSpecification;
import com.opengamma.financial.analytics.conversion.ForexSecurityConverter;
import com.opengamma.financial.analytics.model.forex.forward.FXForwardMultiValuedFunction;
import com.opengamma.financial.security.FinancialSecurity;
import com.opengamma.financial.security.fx.FXForwardSecurity;
import com.opengamma.financial.security.fx.FXUtils;
import com.opengamma.financial.security.fx.NonDeliverableFXForwardSecurity;
import com.opengamma.util.money.Currency;
import com.opengamma.util.money.MultipleCurrencyAmount;
/**
*
*/
public class ForexForwardConstantSpreadThetaFunction extends FXForwardMultiValuedFunction {
private static final ForexSecurityConverter VISITOR = new ForexSecurityConverter();
private static final int DAYS_TO_MOVE_FORWARD = 1; // TODO Add to Value Properties
public ForexForwardConstantSpreadThetaFunction() {
super(ValueRequirementNames.VALUE_THETA);
}
@Override
public Set<ComputedValue> execute(final FunctionExecutionContext executionContext, final FunctionInputs inputs, final ComputationTarget target, final Set<ValueRequirement> desiredValues) {
final Clock snapshotClock = executionContext.getValuationClock();
final ZonedDateTime now = snapshotClock.zonedDateTime();
final FinancialSecurity security = (FinancialSecurity) target.getSecurity();
final Currency payCurrency, receiveCurrency;
if (security instanceof FXForwardSecurity) {
final FXForwardSecurity forward = (FXForwardSecurity) security;
payCurrency = forward.getPayCurrency();
receiveCurrency = forward.getReceiveCurrency();
} else {
final NonDeliverableFXForwardSecurity ndf = (NonDeliverableFXForwardSecurity) security;
payCurrency = ndf.getPayCurrency();
receiveCurrency = ndf.getReceiveCurrency();
}
final ForexDefinition definition = (ForexDefinition) security.accept(VISITOR);
final ValueRequirement desiredValue = desiredValues.iterator().next();
final String payCurveName = desiredValue.getConstraint(ValuePropertyNames.PAY_CURVE);
final String receiveCurveName = desiredValue.getConstraint(ValuePropertyNames.RECEIVE_CURVE);
final String payCurveConfig = desiredValue.getConstraint(PAY_CURVE_CALC_CONFIG);
final String receiveCurveConfig = desiredValue.getConstraint(RECEIVE_CURVE_CALC_CONFIG);
final String fullPutCurveName = payCurveName + "_" + payCurrency.getCode();
final String fullCallCurveName = receiveCurveName + "_" + receiveCurrency.getCode();
final YieldAndDiscountCurve payFundingCurve = getCurve(inputs, payCurrency, payCurveName, payCurveConfig);
final YieldAndDiscountCurve receiveFundingCurve = getCurve(inputs, receiveCurrency, receiveCurveName, receiveCurveConfig);
final YieldAndDiscountCurve[] curves;
final Map<String, Currency> curveCurrency = new HashMap<String, Currency>();
curveCurrency.put(fullPutCurveName, payCurrency);
curveCurrency.put(fullCallCurveName, receiveCurrency);
final String[] allCurveNames;
if (FXUtils.isInBaseQuoteOrder(payCurrency, receiveCurrency)) { // To get Base/quote in market standard order.
curves = new YieldAndDiscountCurve[] {payFundingCurve, receiveFundingCurve};
allCurveNames = new String[] {fullPutCurveName, fullCallCurveName};
} else {
curves = new YieldAndDiscountCurve[] {receiveFundingCurve, payFundingCurve};
allCurveNames = new String[] {fullCallCurveName, fullPutCurveName};
}
final YieldCurveBundle yieldCurves = new YieldCurveBundle(allCurveNames, curves);
final ValueProperties.Builder properties = getResultProperties(target, desiredValue);
final ValueSpecification spec = new ValueSpecification(ValueRequirementNames.VALUE_THETA, target.toSpecification(), properties.get());
final ConstantSpreadHorizonThetaCalculator calculator = ConstantSpreadHorizonThetaCalculator.getInstance();
final MultipleCurrencyAmount theta = calculator.getTheta(definition, now, allCurveNames, yieldCurves, DAYS_TO_MOVE_FORWARD);
return Collections.singleton(new ComputedValue(spec, theta));
}
@Override
protected ValueProperties.Builder getResultProperties(final ComputationTarget target) {
final ValueProperties.Builder properties = super.getResultProperties(target);
properties.with(InterestRateFutureConstantSpreadThetaFunction.PROPERTY_THETA_CALCULATION_METHOD, InterestRateFutureConstantSpreadThetaFunction.THETA_CONSTANT_SPREAD);
return properties;
}
@Override
protected ValueProperties.Builder getResultProperties(final ComputationTarget target, final ValueRequirement desiredValue) {
final ValueProperties.Builder properties = super.getResultProperties(target, desiredValue);
properties.with(InterestRateFutureConstantSpreadThetaFunction.PROPERTY_THETA_CALCULATION_METHOD, InterestRateFutureConstantSpreadThetaFunction.THETA_CONSTANT_SPREAD);
return properties;
}
@Override
protected Set<ComputedValue> getResult(final Forex fxForward, final YieldCurveBundle data, final ComputationTarget target, final Set<ValueRequirement> desiredValues, final FunctionInputs inputs,
final ValueSpecification spec, final FunctionExecutionContext executionContext) {
throw new NotImplementedException("Should never get here");
}
}
|
[
"elaine@opengamma.com"
] |
elaine@opengamma.com
|
adfa351397877c305934a91a572bf24d82bd897f
|
605c28cc4d7ffd35583f6aba8cc58c7068f237e2
|
/src/com/dxjr/portal/tzjinterface/entity/RepayInfo.java
|
2069d7e979e3117f00c5d17b34d59be51c838f1d
|
[] |
no_license
|
Lwb6666/dxjr_portal
|
7ffb56c79f0bd07a39ac94f30b2280f7cc98a2e4
|
cceef6ee83d711988e9d1340f682e0782e392ba0
|
refs/heads/master
| 2023-04-21T07:38:25.528219
| 2021-05-10T02:47:22
| 2021-05-10T02:47:22
| 351,003,513
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,630
|
java
|
package com.dxjr.portal.tzjinterface.entity;
import java.util.Date;
public class RepayInfo {
// 订单ID
private String id;
// 投资订单ID
private String investId;
// 标ID
private String bid;
// 投资者投之家用户名
private String username;
// 回款金额
private Float amount;
// 回款利率
private Float rate;
// 回款收益
private Float income;
// 回款类型:0:普通回款,1:转让回款
private int type;
// 回款时间
private Date repayAt;
// 标签
private String[] tags;
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getInvestId() {
return investId;
}
public void setInvestId(String investId) {
this.investId = investId;
}
public String getBid() {
return bid;
}
public void setBid(String bid) {
this.bid = bid;
}
public String getUsername() {
return username;
}
public void setUsername(String username) {
this.username = username;
}
public Float getAmount() {
return amount;
}
public void setAmount(Float amount) {
this.amount = amount;
}
public Float getRate() {
return rate;
}
public void setRate(Float rate) {
this.rate = rate;
}
public Float getIncome() {
return income;
}
public void setIncome(Float income) {
this.income = income;
}
public int getType() {
return type;
}
public void setType(int type) {
this.type = type;
}
public Date getRepayAt() {
return repayAt;
}
public void setRepayAt(Date repayAt) {
this.repayAt = repayAt;
}
public String[] getTags() {
return tags;
}
public void setTags(String[] tags) {
this.tags = tags;
}
}
|
[
"1677406532@qq.com"
] |
1677406532@qq.com
|
636871305abb27644079e83855032bbfa1acb290
|
052c140d4b06004d8043c7f86b5acff5c1fde220
|
/src/main/java/cn/devezhao/persist4j/metadata/CascadeModel.java
|
a32304cc20d73e53deee6cb7d19ac805d189859d
|
[
"Apache-2.0"
] |
permissive
|
devezhao/persist4j
|
ca0a9a95886beddc91d63955bd0947c5862ea8cf
|
837605e2f0f2832d53d4ce0255ac8a6de53a7400
|
refs/heads/master
| 2023-08-16T22:15:03.942943
| 2023-08-08T03:52:19
| 2023-08-08T03:52:19
| 83,287,183
| 21
| 10
|
Apache-2.0
| 2023-05-19T02:33:35
| 2017-02-27T08:34:57
|
Java
|
UTF-8
|
Java
| false
| false
| 937
|
java
|
package cn.devezhao.persist4j.metadata;
import java.util.HashMap;
import java.util.Map;
/**
* 级联删除模式
*
* @author <a href="mailto:zhaofang123@gmail.com">FANGFANG ZHAO</a>
* @since 0.1, Feb 15, 2009
* @version $Id: CascadeModel.java 8 2015-06-08 09:09:03Z zhaofang123@gmail.com $
*/
public enum CascadeModel {
/**
* 级联删除
*/
Delete,
/**
* 移除链接
*/
RemoveLinks,
/**
* 忽略,啥都不干
*/
Ignore;
private static final Map<String, CascadeModel> NAMED = new HashMap<>();
static {
NAMED.put("delete", Delete);
NAMED.put("remove-links", RemoveLinks);
NAMED.put("removelinks", RemoveLinks);
NAMED.put("ignore", Ignore);
}
/**
* @param model
* @return
*/
public static CascadeModel parse(String model) {
CascadeModel cm = NAMED.get(model.toLowerCase());
if (cm != null) {
return cm;
}
throw new MetadataException("No CascadeModel found: " + model);
}
}
|
[
"zhaofang123@gmail.com"
] |
zhaofang123@gmail.com
|
b4be20d90aaab0dfcdb403198a501993c423da0a
|
ce32decef039a586855c362381003d21d1ab3342
|
/modules/flowable-cmmn-converter/src/main/java/org/flowable/cmmn/converter/TextAnnotationXmlConverter.java
|
5b16ef27279dba1a8eeea155851f4b8c884177ba
|
[
"Apache-2.0"
] |
permissive
|
flowable/flowable-engine
|
fa5fb5c29a453669887bee7874ca6d73fd2663c7
|
7bd4ee8b7374b43dcdd517a26afa14e6806f40e4
|
refs/heads/main
| 2023-08-31T03:55:26.415399
| 2023-08-29T11:53:55
| 2023-08-29T11:53:55
| 70,780,002
| 7,040
| 2,775
|
Apache-2.0
| 2023-09-14T16:51:30
| 2016-10-13T07:21:43
|
Java
|
UTF-8
|
Java
| false
| false
| 1,585
|
java
|
/* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.flowable.cmmn.converter;
import javax.xml.stream.XMLStreamReader;
import org.apache.commons.lang3.StringUtils;
import org.flowable.cmmn.model.CmmnElement;
import org.flowable.cmmn.model.TextAnnotation;
/**
* @author Joram Barrez
*/
public class TextAnnotationXmlConverter extends BaseCmmnXmlConverter {
@Override
public String getXMLElementName() {
return CmmnXmlConstants.ELEMENT_TEXT_ANNOTATION;
}
@Override
public boolean hasChildElements() {
return true;
}
@Override
protected CmmnElement convert(XMLStreamReader xtr, ConversionHelper conversionHelper) {
TextAnnotation textAnnotation = new TextAnnotation();
String textFormat = xtr.getAttributeValue(null, CmmnXmlConstants.ATTRIBUTE_TEXT_FORMAT);
if (StringUtils.isEmpty(textFormat)) {
textAnnotation.setTextFormat(textFormat);
}
conversionHelper.getCmmnModel().addTextAnnotation(textAnnotation);
return textAnnotation;
}
}
|
[
"jbarrez@users.noreply.github.com"
] |
jbarrez@users.noreply.github.com
|
fb24782faea27ca70ace5b0c9874322b98cfad8e
|
96602275a8a9fdd18552df60d3b4ae4fa21034e9
|
/security/skeleton-key-idm/skeleton-key-core/src/main/java/org/jboss/resteasy/skeleton/key/SkeletonKeySession.java
|
8138b34ff4d2b504c758b6cbe1594dbb9358d4ed
|
[
"Apache-2.0"
] |
permissive
|
tedwon/Resteasy
|
03bb419dc9f74ea406dc1ea29d8a6b948b2228a8
|
38badcb8c2daae2a77cea9e7d70a550449550c49
|
refs/heads/master
| 2023-01-18T22:03:43.256889
| 2016-06-29T15:37:45
| 2016-06-29T15:37:45
| 62,353,131
| 0
| 0
|
NOASSERTION
| 2023-01-02T22:02:20
| 2016-07-01T01:29:16
|
Java
|
UTF-8
|
Java
| false
| false
| 659
|
java
|
package org.jboss.resteasy.skeleton.key;
import java.io.Serializable;
/**
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
* @version $Revision: 1 $
*/
public class SkeletonKeySession implements Serializable
{
protected String token;
protected transient ResourceMetadata metadata;
public SkeletonKeySession()
{
}
public SkeletonKeySession(String token, ResourceMetadata metadata)
{
this.token = token;
this.metadata = metadata;
}
public String getToken()
{
return token;
}
public ResourceMetadata getMetadata()
{
return metadata;
}
}
|
[
"bburke@redhat.com"
] |
bburke@redhat.com
|
9b51abcf5e289a7391ff0bf362fac4f5f5c00e44
|
97c2cfd517cdf2a348a3fcb73e9687003f472201
|
/workspace/fftw-pomsfa/tags/fftw-pomsfa-1.4.6/src/main/java/malbec/pomsfa/fix/TradingScreenFixClientApplication.java
|
25ceadc3d54b3f9f663f103da74fc8be693c5213
|
[] |
no_license
|
rsheftel/ratel
|
b1179fcc1ca55255d7b511a870a2b0b05b04b1a0
|
e1876f976c3e26012a5f39707275d52d77f329b8
|
refs/heads/master
| 2016-09-05T21:34:45.510667
| 2015-05-12T03:51:05
| 2015-05-12T03:51:05
| 32,461,975
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 875
|
java
|
package malbec.pomsfa.fix;
import java.util.Properties;
import malbec.fer.mapping.DatabaseMapper;
import malbec.util.EmailSettings;
import com.fftw.bloomberg.aggregator.TradingScreenConversionStrategy;
import com.fftw.bloomberg.types.TradingPlatform;
/**
* TradingScreen specific implementation for converting FIX messages into CMF
* messages
*
*/
public class TradingScreenFixClientApplication extends FeedAggregatorFixClientApplication
{
// final private Logger log = LoggerFactory.getLogger(getClass());
public TradingScreenFixClientApplication (String name, Properties config,
EmailSettings emailSettings, DatabaseMapper dbm)
{
super(name, config, emailSettings, new TradingScreenConversionStrategy(dbm));
}
@Override
protected TradingPlatform getPlatform ()
{
return TradingPlatform.TradingScreen;
}
}
|
[
"rsheftel@gmail.com"
] |
rsheftel@gmail.com
|
ee635e12507a93aa183582969a8a17bcde2e93e6
|
8a16f2ed17b477c88dd001afc9f29282cdbc6758
|
/src/main/java/ch/kerbtier/esdi/providers/DefaultProvider.java
|
13e728c2afcab347377c4366dc793ccd32336c43
|
[] |
no_license
|
creichlin/esdi
|
c63b136ae65360190d5114efe0545f3c0c021ab4
|
93b61e38027d505b1f6b40a7701440323949909d
|
refs/heads/master
| 2021-01-17T09:24:40.553677
| 2016-04-10T18:19:03
| 2016-04-10T18:19:03
| 41,487,132
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,105
|
java
|
package ch.kerbtier.esdi.providers;
import java.lang.annotation.Annotation;
import ch.kerbtier.esdi.Configuration;
import ch.kerbtier.esdi.Provider;
/**
* This default provider is used as default and also used by other Providers
* which get the instance from here and then cache/store it in different ways.
*
*
* default provider creates a new instance for each request if class is set. If
* instance is given returns this instance and if threadlocal is given gets the
* value of it.
*
*/
public class DefaultProvider implements Provider {
@Override
public Object get(Configuration configuration, Annotation annotation) {
try {
if (configuration.getInstance() != null) {
return configuration.getInstance();
} else if (configuration.getThreadLocal() != null) {
return configuration.getThreadLocal().get();
} else {
return configuration.getImplementation().newInstance();
}
} catch (Exception e) {
throw new RuntimeException(e);
}
}
@Override
public void clear() {
// no caching so no clearing necessary
}
}
|
[
"chrigi@kerbtier.ch"
] |
chrigi@kerbtier.ch
|
6c8df769cb47425df0321880bcd2e26db170042a
|
5e3235edf3de262f4d10b9e9e1fcc3bd13d6b8b1
|
/Code Snippet Repository/Jetty/Jetty1317.java
|
935a234bd43f10c4b81e87700c1fa38f8ebd1163
|
[] |
no_license
|
saber13812002/DeepCRM
|
3336a244d4852a364800af3181e03e868cf6f9f5
|
be3e5e50e34a042d5ba7259ff5ff75c08ab32bb9
|
refs/heads/master
| 2023-03-16T00:08:06.473699
| 2018-04-18T05:29:50
| 2018-04-18T05:29:50
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 344
|
java
|
private static void putSanitisedValue(String s,ByteBuffer buffer)
{
int l=s.length();
for (int i=0;i<l;i++)
{
char c=s.charAt(i);
if (c<0 || c>0xff || c=='\r' || c=='\n')
buffer.put((byte)' ');
else
buffer.put((byte)(0xff&c));
}
}
|
[
"Qing.Mi@my.cityu.edu.hk"
] |
Qing.Mi@my.cityu.edu.hk
|
e2ca943ad214619b542493c61e59cd0548faf071
|
e680c1483a143a40fd5d92e0e0befbd9e2dcdf0d
|
/split-linked-list-in-parts/Solution.java
|
0b7fc7288ebad15298b1f9ec6132865d41615e39
|
[] |
no_license
|
grvgoel81/leetcode
|
a715ddb35442bbda21b66ecd88eb55bca2d836da
|
e490d6b109890db104ceeb3647bb60f954ca2bcf
|
refs/heads/master
| 2022-08-19T10:24:08.871144
| 2020-05-26T10:12:08
| 2020-05-26T10:12:08
| 267,265,566
| 1
| 0
| null | 2020-05-27T08:36:19
| 2020-05-27T08:36:18
| null |
UTF-8
|
Java
| false
| false
| 958
|
java
|
// Definition for singly-linked list.
class ListNode {
int val;
ListNode next;
ListNode(int x) {
val = x;
}
}
public class Solution {
public ListNode[] splitListToParts(ListNode root, int k) {
int length = getLength(root);
int averageLength = length / k;
int extraPartNum = length % k;
ListNode[] parts = new ListNode[k];
for (int i = 0; i < parts.length; i++) {
ListNode tempHead = new ListNode(0);
root = retrieve(root, tempHead, averageLength + (i < extraPartNum ? 1 : 0));
parts[i] = tempHead.next;
}
return parts;
}
ListNode retrieve(ListNode root, ListNode tempHead, int partLength) {
ListNode prev = tempHead;
for (int i = 0; i < partLength; i++) {
ListNode node = root;
root = root.next;
node.next = null;
prev.next = node;
prev = node;
}
return root;
}
int getLength(ListNode root) {
int length = 0;
while (root != null) {
root = root.next;
length++;
}
return length;
}
}
|
[
"charles.wangkai@gmail.com"
] |
charles.wangkai@gmail.com
|
084d35b4013edb7afb9451f267444588c530dd13
|
8009fa2efff68fe23391e0002eb3bb7721518a72
|
/tokTales-core/tokTales-core-library/src/main/java/com/tokelon/toktales/core/render/opengl/gl20/GLErrorUtils.java
|
0a12bb7d0866cc120deff4a9e59fb6be8b0b26c5
|
[
"MIT"
] |
permissive
|
Tokelon/tokTales
|
3bdf2c08d71d8a81d417971dddff404c3ea89b54
|
c72c67519af57cc28a0699766083559a0731ba4c
|
refs/heads/master
| 2022-07-23T20:51:02.780796
| 2021-03-14T16:42:10
| 2021-03-14T16:42:10
| 110,269,279
| 5
| 0
|
MIT
| 2020-12-04T18:32:22
| 2017-11-10T16:39:00
|
Java
|
UTF-8
|
Java
| false
| false
| 3,676
|
java
|
package com.tokelon.toktales.core.render.opengl.gl20;
import java.io.PrintWriter;
import java.io.StringWriter;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import javax.inject.Inject;
import com.tokelon.toktales.core.engine.log.ILogger;
import com.tokelon.toktales.core.engine.log.ILogging;
import com.tokelon.toktales.core.render.opengl.GLErrorCheckingEnabled;
import com.tokelon.toktales.core.render.opengl.IGLErrorUtils;
import com.tokelon.toktales.core.render.opengl.OpenGLErrorException;
public class GLErrorUtils implements IGLErrorUtils {
private static final List<IGLError> emptyErrorList = Collections.unmodifiableList(new ArrayList<>());
private boolean enableErrorChecking = false; // Implementation default must be false
private final ILogger logger;
private final IGL11 gl11;
@Inject
public GLErrorUtils(ILogging logging, IGL11 gl11, @GLErrorCheckingEnabled boolean enabled) {
this.logger = logging.getLogger(getClass());
this.gl11 = gl11;
this.enableErrorChecking = enabled;
}
@Override
public void enableErrorChecking(boolean enabled) {
this.enableErrorChecking = enabled;
}
@Override
public boolean isErrorCheckingEnabled() {
return enableErrorChecking;
}
@Override
public void assertNoGLErrors() throws OpenGLErrorException {
if(!enableErrorChecking) {
return;
}
List<IGLError> errorList = getGLErrors();
if(errorList.size() > 0) {
throw new OpenGLErrorException(errorList);
}
}
@Override
public int logGLErrors(String context) {
if(!enableErrorChecking) {
return 0;
}
StringBuilder strBuilder = null;
int lastError;
int errorCount = 0;
while((lastError = gl11.glGetError()) != IGL11.GL_NO_ERROR) {
// Initialize
if(errorCount == 0) {
strBuilder = new StringBuilder();
strBuilder.append("Getting GL errors | Context: " + context + "\n");
}
strBuilder.append(createGLErrorMessage(lastError));
strBuilder.append("\n");
errorCount++;
}
if(errorCount > 0) {
strBuilder.append("Stacktrace:\n");
StringWriter sw = new StringWriter();
new Throwable().printStackTrace(new PrintWriter(sw));
strBuilder.append(sw.toString());
logger.error(strBuilder.toString());
}
return errorCount;
}
@Override
public List<IGLError> getGLErrors() {
if(!enableErrorChecking) {
return emptyErrorList;
}
ArrayList<IGLError> result = null;
int lastError;
while((lastError = gl11.glGetError()) != IGL11.GL_NO_ERROR) {
String errorMessage = createGLErrorMessage(lastError);
if(result == null) {
result = new ArrayList<>();
}
result.add(new GLError(lastError, errorMessage));
}
return result == null ? emptyErrorList : result;
}
private static String createGLErrorMessage(int glErrorCode) {
String name;
switch (glErrorCode) {
case IGL11.GL_INVALID_ENUM:
name = "GL_INVALID_ENUM";
break;
case IGL11.GL_INVALID_VALUE:
name = "GL_INVALID_VALUE";
break;
case IGL11.GL_INVALID_OPERATION:
name = "GL_INVALID_OPERATION";
break;
case IGL11.GL_OUT_OF_MEMORY:
name = "GL_OUT_OF_MEMORY";
break;
default:
name = "ERROR CODE";
break;
}
return String.format("%s (%d)", name, glErrorCode);
}
private static class GLError implements IGLError {
private final int errorCode;
private final String errorMessage;
public GLError(int errorCode, String errorMessage) {
this.errorCode = errorCode;
this.errorMessage = errorMessage;
}
@Override
public int getErrorCode() {
return errorCode;
}
@Override
public String getErrorMessage() {
return errorMessage;
}
}
}
|
[
"tokelontales@gmail.com"
] |
tokelontales@gmail.com
|
f2f64ddb29b9d5d382c3de0c09c1dba413414105
|
bec576edd56ff483ff365072ce1811c7869f5d89
|
/ReactAndroid/src/main/java/com/facebook/hermes/reactexecutor/HermesExecutorFactory.java
|
944afe6b64568d0eb58b7effc50cacb7a478ab90
|
[
"CC-BY-SA-4.0",
"CC-BY-4.0",
"CC-BY-NC-SA-4.0",
"MIT"
] |
permissive
|
RocketChat/react-native
|
3cdf5e4f7e864cfea09dc03613d40d6970e67016
|
43f831b23caf22e59af5c6d3fdd62fed3d20d4ec
|
refs/heads/main
| 2023-08-30T12:07:01.015956
| 2022-06-07T14:42:49
| 2022-06-07T14:42:49
| 310,372,603
| 1
| 3
|
MIT
| 2023-09-14T18:20:36
| 2020-11-05T17:33:10
|
JavaScript
|
UTF-8
|
Java
| false
| false
| 1,162
|
java
|
/*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
package com.facebook.hermes.reactexecutor;
import com.facebook.hermes.instrumentation.HermesSamplingProfiler;
import com.facebook.react.bridge.JavaScriptExecutor;
import com.facebook.react.bridge.JavaScriptExecutorFactory;
public class HermesExecutorFactory implements JavaScriptExecutorFactory {
private static final String TAG = "Hermes";
private final RuntimeConfig mConfig;
public HermesExecutorFactory() {
this(null);
}
public HermesExecutorFactory(RuntimeConfig config) {
mConfig = config;
}
@Override
public JavaScriptExecutor create() {
return new HermesExecutor(mConfig);
}
@Override
public void startSamplingProfiler() {
HermesSamplingProfiler.enable();
}
@Override
public void stopSamplingProfiler(String filename) {
HermesSamplingProfiler.dumpSampledTraceToFile(filename);
HermesSamplingProfiler.disable();
}
@Override
public String toString() {
return "JSIExecutor+HermesRuntime";
}
}
|
[
"facebook-github-bot@users.noreply.github.com"
] |
facebook-github-bot@users.noreply.github.com
|
34419e1ba6b0811447802e7b6eb2a356209886c6
|
c90d3fee49b41de5263b00069e99422c7139a70b
|
/jax-ws-basics/src/com/msrm/webservice/example2/PersonClient.java
|
3c14fa3f8ae3576da9471794a522690472f7ac92
|
[] |
no_license
|
srirambtechit/j2ee-technology
|
807aa000e97a8bf25bbeea04be54299a8473cec7
|
ece4e1f66447d9c830756000ffec396cacc7190e
|
refs/heads/master
| 2021-01-19T02:48:57.060808
| 2016-12-25T18:06:15
| 2016-12-25T18:06:15
| 55,084,863
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,030
|
java
|
package com.msrm.webservice.example2;
import java.net.MalformedURLException;
import java.net.URL;
import javax.xml.namespace.QName;
import javax.xml.ws.Service;
/**
* To generate Stub code of webservice.
* <code>wsimport -s . http://localhost:8888/personWS?wsdl</code>
* @author srirammuthaiah
*
*/
public class PersonClient {
public static void main(String[] args) throws MalformedURLException {
URL wsdlUrl = new URL("http://localhost:8888/personWS?wsdl");
QName serviceName = new QName("http://example2.webservice.msrm.com/", "PersonServiceImplService");
Service service = Service.create(wsdlUrl, serviceName);
PersonService personService = service.getPort(PersonService.class);
Person person1 = new Person(1, "Sriram", 3001.25f);
Person person2 = new Person(2, "Praveen", 3211.22f);
Person person3 = new Person(3, "Soma sundarraj", 3200.32f);
personService.add(person1);
personService.add(person2);
personService.add(person3);
personService.getAllPerson().forEach(System.out::println);
}
}
|
[
"srirambtecit@gmail.com"
] |
srirambtecit@gmail.com
|
612c25e02ff529f513a2f9394cc652d8116a30bc
|
13a248a094910d308dcbe772e92229ed2ee682b6
|
/src/main/java/lists/IntersectionPointOfTwo2.java
|
4d9a3f74f8533c28aefd239abb556764d7b09fe2
|
[] |
no_license
|
gadzikk/algorithms
|
cca18ab79b8e1e766f7d6fc9b9097db2077cb93b
|
cb6607ad19b43357c225e9531d3ebc115ef1de3a
|
refs/heads/master
| 2022-12-07T16:22:36.958374
| 2020-08-23T21:35:56
| 2020-08-23T21:35:56
| 273,081,100
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,421
|
java
|
package lists;
import zobjects.NodeL;
import java.util.HashSet;
/**
* Created by gadzik on 22.07.20.
*/
public class IntersectionPointOfTwo2 {
// https://www.geeksforgeeks.org/write-a-function-to-get-the-intersection-point-of-two-linked-lists/
public static NodeL MegeNode(NodeL n1, NodeL n2) {
HashSet<NodeL> hs = new HashSet<>();
while (n1 != null) {
hs.add(n1);
n1 = n1.next;
}
while (n2 != null) {
if (hs.contains(n2)) {
return n2;
}
n2 = n2.next;
}
return null;
}
public static void Print(NodeL n) {
NodeL cur = n;
while (cur != null) {
System.out.print(cur.data + " ");
cur = cur.next;
}
System.out.println();
}
public static void main(String[] args) {
NodeL n1 = new NodeL(1);
n1.next = new NodeL(2);
n1.next.next = new NodeL(3);
n1.next.next.next = new NodeL(4);
n1.next.next.next.next = new NodeL(5);
n1.next.next.next.next.next = new NodeL(6);
n1.next.next.next.next.next.next = new NodeL(7);
NodeL n2 = new NodeL(10);
n2.next = new NodeL(9);
n2.next.next = new NodeL(8);
n2.next.next.next = n1.next.next.next;
Print(n1);
Print(n2);
System.out.println(MegeNode(n1, n2).data);
}
}
|
[
"glina41@o2.pl"
] |
glina41@o2.pl
|
8e77b4a3a94c0642996b156d044cb6a1f2e8a1a9
|
fac5d6126ab147e3197448d283f9a675733f3c34
|
/src/main/java/dji/thirdparty/sanselan/formats/tiff/write/TiffOutputSet.java
|
93174ee47bd22e2b10b4b90e29ee3c5ddc6d3da9
|
[] |
no_license
|
KnzHz/fpv_live
|
412e1dc8ab511b1a5889c8714352e3a373cdae2f
|
7902f1a4834d581ee6afd0d17d87dc90424d3097
|
refs/heads/master
| 2022-12-18T18:15:39.101486
| 2020-09-24T19:42:03
| 2020-09-24T19:42:03
| 294,176,898
| 0
| 0
| null | 2020-09-09T17:03:58
| 2020-09-09T17:03:57
| null |
UTF-8
|
Java
| false
| false
| 7,693
|
java
|
package dji.thirdparty.sanselan.formats.tiff.write;
import dji.thirdparty.sanselan.ImageWriteException;
import dji.thirdparty.sanselan.formats.tiff.constants.TagInfo;
import dji.thirdparty.sanselan.formats.tiff.constants.TiffConstants;
import dji.thirdparty.sanselan.util.Debug;
import java.util.ArrayList;
import java.util.List;
public final class TiffOutputSet implements TiffConstants {
private static final String newline = System.getProperty("line.separator");
public final int byteOrder;
private final ArrayList directories;
public TiffOutputSet() {
this(73);
}
public TiffOutputSet(int byteOrder2) {
this.directories = new ArrayList();
this.byteOrder = byteOrder2;
}
/* access modifiers changed from: protected */
public List getOutputItems(TiffOutputSummary outputSummary) throws ImageWriteException {
List result = new ArrayList();
for (int i = 0; i < this.directories.size(); i++) {
result.addAll(((TiffOutputDirectory) this.directories.get(i)).getOutputItems(outputSummary));
}
return result;
}
public void addDirectory(TiffOutputDirectory directory) throws ImageWriteException {
if (findDirectory(directory.type) != null) {
throw new ImageWriteException("Output set already contains a directory of that type.");
}
this.directories.add(directory);
}
public List getDirectories() {
return new ArrayList(this.directories);
}
public TiffOutputDirectory getRootDirectory() {
return findDirectory(0);
}
public TiffOutputDirectory getExifDirectory() {
return findDirectory(-2);
}
public TiffOutputDirectory getOrCreateRootDirectory() throws ImageWriteException {
TiffOutputDirectory result = findDirectory(0);
return result != null ? result : addRootDirectory();
}
public TiffOutputDirectory getOrCreateExifDirectory() throws ImageWriteException {
getOrCreateRootDirectory();
TiffOutputDirectory result = findDirectory(-2);
return result != null ? result : addExifDirectory();
}
public TiffOutputDirectory getOrCreateGPSDirectory() throws ImageWriteException {
getOrCreateExifDirectory();
TiffOutputDirectory result = findDirectory(-3);
return result != null ? result : addGPSDirectory();
}
public TiffOutputDirectory getGPSDirectory() {
return findDirectory(-3);
}
public TiffOutputDirectory getInteroperabilityDirectory() {
return findDirectory(-4);
}
public TiffOutputDirectory findDirectory(int directoryType) {
for (int i = 0; i < this.directories.size(); i++) {
TiffOutputDirectory directory = (TiffOutputDirectory) this.directories.get(i);
if (directory.type == directoryType) {
return directory;
}
}
return null;
}
public void setGPSInDegrees(double longitude, double latitude) throws ImageWriteException {
TiffOutputDirectory gpsDirectory = getOrCreateGPSDirectory();
String longitudeRef = longitude < 0.0d ? "W" : "E";
double longitude2 = Math.abs(longitude);
String latitudeRef = latitude < 0.0d ? "S" : "N";
double latitude2 = Math.abs(latitude);
TiffOutputField longitudeRefField = TiffOutputField.create(TiffConstants.GPS_TAG_GPS_LONGITUDE_REF, this.byteOrder, longitudeRef);
gpsDirectory.removeField(TiffConstants.GPS_TAG_GPS_LONGITUDE_REF);
gpsDirectory.add(longitudeRefField);
TiffOutputField latitudeRefField = TiffOutputField.create(TiffConstants.GPS_TAG_GPS_LATITUDE_REF, this.byteOrder, latitudeRef);
gpsDirectory.removeField(TiffConstants.GPS_TAG_GPS_LATITUDE_REF);
gpsDirectory.add(latitudeRefField);
double value = longitude2;
double longitudeDegrees = (double) ((long) value);
double value2 = (value % 1.0d) * 60.0d;
TiffOutputField longitudeField = TiffOutputField.create(TiffConstants.GPS_TAG_GPS_LONGITUDE, this.byteOrder, new Double[]{new Double(longitudeDegrees), new Double((double) ((long) value2)), new Double((value2 % 1.0d) * 60.0d)});
gpsDirectory.removeField(TiffConstants.GPS_TAG_GPS_LONGITUDE);
gpsDirectory.add(longitudeField);
double value3 = latitude2;
double latitudeDegrees = (double) ((long) value3);
double value4 = (value3 % 1.0d) * 60.0d;
TiffOutputField latitudeField = TiffOutputField.create(TiffConstants.GPS_TAG_GPS_LATITUDE, this.byteOrder, new Double[]{new Double(latitudeDegrees), new Double((double) ((long) value4)), new Double((value4 % 1.0d) * 60.0d)});
gpsDirectory.removeField(TiffConstants.GPS_TAG_GPS_LATITUDE);
gpsDirectory.add(latitudeField);
}
public void removeField(TagInfo tagInfo) {
removeField(tagInfo.tag);
}
public void removeField(int tag) {
for (int i = 0; i < this.directories.size(); i++) {
((TiffOutputDirectory) this.directories.get(i)).removeField(tag);
}
}
public TiffOutputField findField(TagInfo tagInfo) {
return findField(tagInfo.tag);
}
public TiffOutputField findField(int tag) {
for (int i = 0; i < this.directories.size(); i++) {
TiffOutputField field = ((TiffOutputDirectory) this.directories.get(i)).findField(tag);
if (field != null) {
return field;
}
}
return null;
}
public TiffOutputDirectory addRootDirectory() throws ImageWriteException {
TiffOutputDirectory result = new TiffOutputDirectory(0);
addDirectory(result);
return result;
}
public TiffOutputDirectory addExifDirectory() throws ImageWriteException {
TiffOutputDirectory result = new TiffOutputDirectory(-2);
addDirectory(result);
return result;
}
public TiffOutputDirectory addGPSDirectory() throws ImageWriteException {
TiffOutputDirectory result = new TiffOutputDirectory(-3);
addDirectory(result);
return result;
}
public TiffOutputDirectory addInteroperabilityDirectory() throws ImageWriteException {
getOrCreateExifDirectory();
TiffOutputDirectory result = new TiffOutputDirectory(-4);
addDirectory(result);
return result;
}
public String toString() {
return toString(null);
}
public String toString(String prefix) {
if (prefix == null) {
prefix = "";
}
StringBuffer result = new StringBuffer();
result.append(prefix);
result.append("TiffOutputSet {");
result.append(newline);
result.append(prefix);
result.append("byteOrder: " + this.byteOrder);
result.append(newline);
for (int i = 0; i < this.directories.size(); i++) {
TiffOutputDirectory directory = (TiffOutputDirectory) this.directories.get(i);
result.append(prefix);
result.append("\tdirectory " + i + ": " + directory.description() + " (" + directory.type + ")");
result.append(newline);
ArrayList fields = directory.getFields();
for (int j = 0; j < fields.size(); j++) {
result.append(prefix);
result.append("\t\tfield " + i + ": " + ((TiffOutputField) fields.get(j)).tagInfo);
result.append(newline);
}
}
result.append(prefix);
result.append("}");
result.append(newline);
return result.toString();
}
public void dump() {
Debug.debug(toString());
}
}
|
[
"michael@districtrace.com"
] |
michael@districtrace.com
|
3e478c4d8b6d5cff83d55d367e9ad4cc66211722
|
53efcbcb8210a01c3a57cdc2784926ebc22d6412
|
/src/main/java/br/com/fieesq/model55221/FieEsq51252.java
|
5962533f18da0e1d30d6e309d48b878ff49f1a83
|
[] |
no_license
|
fie23777/frontCercamento
|
d57846ac985f4023a8104a0872ca4a226509bbf2
|
6282f842544ab4ea332fe7802d08cf4e352f0ae3
|
refs/heads/master
| 2021-04-27T17:29:56.793349
| 2018-02-21T10:32:23
| 2018-02-21T10:32:23
| 122,322,301
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 768
|
java
|
package br.com.fieesq.model55221;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Transient;
@Entity
public class FieEsq51252 {
@Id @GeneratedValue(strategy=GenerationType.IDENTITY)
private int id;
private String numEsq51252;
@Transient
private String esqParam;
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getNumEsq51252() {
return numEsq51252;
}
public void setNumEsq51252(String numEsq51252) {
this.numEsq51252 = numEsq51252;
}
public String getEsqParam() {
return esqParam;
}
public void setEsqParam(String esqParam) {
this.esqParam = esqParam;
}
}
|
[
"fie2377@gmail.com"
] |
fie2377@gmail.com
|
29a71afe75dac285f150c77e4468588ab0e0a1e3
|
4438e0d6d65b9fd8c782d5e13363f3990747fb60
|
/mobile-dto/src/main/java/com/cencosud/mobile/dto/users/CumplimientoCabeceraDTO.java
|
458f1a1a09b054ce7c050792b46f36e2f3547625
|
[] |
no_license
|
cencosudweb/mobile
|
82452af7da189ed6f81637f8ebabea0dbd241b4a
|
37a3a514b48d09b9dc93e90987715d979e5414b6
|
refs/heads/master
| 2021-09-01T21:41:24.713624
| 2017-12-28T19:34:28
| 2017-12-28T19:34:28
| 115,652,291
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,948
|
java
|
/**
*@name CumplimientoCabeceraDTO.java
*
*@version 1.0
*
*@date 15-05-2017
*
*@author EA7129
*
*@copyright Cencosud. All rights reserved.
*/
package com.cencosud.mobile.dto.users;
import java.io.Serializable;
import org.apache.commons.lang.builder.ToStringBuilder;
/**
* @description
*/
public class CumplimientoCabeceraDTO implements Serializable{
private static final long serialVersionUID = -262289197062914696L;
private Long id;
private String fechaCompromiso;
private int cantidad;
private int total;
private float porcentaje;
public CumplimientoCabeceraDTO() {
}
public CumplimientoCabeceraDTO(Long id) {
this.id = id;
}
@Override
public String toString() {
return ToStringBuilder.reflectionToString(this);
}
/**
* @return the id
*/
public Long getId() {
return id;
}
/**
* @param id the id to set
*/
public void setId(Long id) {
this.id = id;
}
/**
* @return the fechaCompromiso
*/
public String getFechaCompromiso() {
return fechaCompromiso;
}
/**
* @param fechaCompromiso the fechaCompromiso to set
*/
public void setFechaCompromiso(String fechaCompromiso) {
this.fechaCompromiso = fechaCompromiso;
}
/**
* @return the cantidad
*/
public int getCantidad() {
return cantidad;
}
/**
* @param cantidad the cantidad to set
*/
public void setCantidad(int cantidad) {
this.cantidad = cantidad;
}
/**
* @return the total
*/
public int getTotal() {
return total;
}
/**
* @param total the total to set
*/
public void setTotal(int total) {
this.total = total;
}
/**
* @return the porcentaje
*/
public float getPorcentaje() {
return porcentaje;
}
/**
* @param porcentaje the porcentaje to set
*/
public void setPorcentaje(float porcentaje) {
this.porcentaje = porcentaje;
}
}
|
[
"cencosudweb.panel@gmail.com"
] |
cencosudweb.panel@gmail.com
|
ff2c099c62d40dc5de20247ef96284a6886fdbfa
|
bed2114715ce6e89a87d6addb134f19902e0a256
|
/src/main/java/eu/seaclouds/platform/repository/RepositoryApplication.java
|
bc02829e7b0cb68597c33ef438c668e5552a389b
|
[] |
no_license
|
rosogon/repository
|
b00112d9c0fb54d19a40406af91ddc6cb062672e
|
16ab8f3b74f9adb8d406fbd8e861acff25f72104
|
refs/heads/master
| 2021-01-15T22:34:44.041676
| 2017-08-10T09:12:46
| 2017-08-10T09:12:46
| 99,903,324
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 883
|
java
|
package eu.seaclouds.platform.repository;
import org.glassfish.jersey.media.multipart.MultiPartFeature;
import eu.seaclouds.platform.repository.resources.DataResource;
import io.dropwizard.Application;
import io.dropwizard.setup.Environment;
public class RepositoryApplication extends Application<RepositoryConfiguration> {
public static void main(String[] args) throws Exception {
new RepositoryApplication().run(args);
}
public RepositoryApplication() {
}
@Override
public void run(RepositoryConfiguration configuration, Environment environment) throws Exception {
DataResource data = new DataResource();
environment.jersey().register(MultiPartFeature.class);
environment.jersey().register(data);
}
@Override
public String getName() {
return "repository-service";
}
}
|
[
"roman.sosa@atos.net"
] |
roman.sosa@atos.net
|
8dfcf33ab645013db069e304bee0f1c8bf815418
|
f9d8b48eed19569d478bbce70eee2eeb544d8cf6
|
/ripple-bouncycastle/src/main/java/org/ripple/bouncycastle/crypto/tls/DTLSTransport.java
|
715da835da05dcf455237d690223167fe534a6ff
|
[
"MIT",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
moorecoin/MooreClient
|
52e3e822f65d93fc4c7f817a936416bfdf060000
|
68949cf6d1a650dd8dd878f619a874888b201a70
|
refs/heads/master
| 2021-01-10T06:06:26.239954
| 2015-11-14T15:39:44
| 2015-11-14T15:39:44
| 46,180,336
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,941
|
java
|
package org.ripple.bouncycastle.crypto.tls;
import java.io.ioexception;
public class dtlstransport
implements datagramtransport
{
private final dtlsrecordlayer recordlayer;
dtlstransport(dtlsrecordlayer recordlayer)
{
this.recordlayer = recordlayer;
}
public int getreceivelimit()
throws ioexception
{
return recordlayer.getreceivelimit();
}
public int getsendlimit()
throws ioexception
{
return recordlayer.getsendlimit();
}
public int receive(byte[] buf, int off, int len, int waitmillis)
throws ioexception
{
try
{
return recordlayer.receive(buf, off, len, waitmillis);
}
catch (tlsfatalalert fatalalert)
{
recordlayer.fail(fatalalert.getalertdescription());
throw fatalalert;
}
catch (ioexception e)
{
recordlayer.fail(alertdescription.internal_error);
throw e;
}
catch (runtimeexception e)
{
recordlayer.fail(alertdescription.internal_error);
throw new tlsfatalalert(alertdescription.internal_error);
}
}
public void send(byte[] buf, int off, int len)
throws ioexception
{
try
{
recordlayer.send(buf, off, len);
}
catch (tlsfatalalert fatalalert)
{
recordlayer.fail(fatalalert.getalertdescription());
throw fatalalert;
}
catch (ioexception e)
{
recordlayer.fail(alertdescription.internal_error);
throw e;
}
catch (runtimeexception e)
{
recordlayer.fail(alertdescription.internal_error);
throw new tlsfatalalert(alertdescription.internal_error);
}
}
public void close()
throws ioexception
{
recordlayer.close();
}
}
|
[
"mooreccc@foxmail.com"
] |
mooreccc@foxmail.com
|
1c2389ec5e7d5b640b3fd214e52f39d662629346
|
8dfd406e855dbef74ef6b80e7b1fcde43d0b7d56
|
/Web-Stock1.0/src/main/java/com/cyb/config/EmailConfigSettings.java
|
93bd9ea48edfb161ff3bed6a8e3203cdbb6d9366
|
[] |
no_license
|
iechenyb/springboot
|
db0e4caaf545721f5b6a70d97cce2af2cbbd0797
|
46e541a6319bfced7d2445038464ce249b409e83
|
refs/heads/master
| 2021-01-20T01:35:04.050414
| 2019-05-16T02:02:04
| 2019-05-16T02:02:04
| 89,299,676
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 636
|
java
|
package com.cyb.config;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;
/**
* 作者 : iechenyb<br>
* 类描述: 说点啥<br>
* 创建时间: 2018年3月1日
*/
@Component
@ConfigurationProperties(prefix = "spring.boot.admin.notify.mail")
public class EmailConfigSettings {
private String from;
private String to;
public String getFrom() {
return from;
}
public void setFrom(String from) {
this.from = from;
}
public String getTo() {
return to;
}
public void setTo(String to) {
this.to = to;
}
}
|
[
"zzuchenyb@sina.com"
] |
zzuchenyb@sina.com
|
9ac61adc3c22bdfe6a1e201bb50129b2b9b70b1d
|
37baf20f48cffee5d8087cfbd022ca81c5097a9a
|
/Java/video/datastruct&algorithms/src/com/shma/graph/Queue.java
|
93f6751b97be62f707339bd73830e9c6108b72d5
|
[] |
no_license
|
shma1664/Project
|
c4feabb9b3616256b43f967414d357e6c10f05e4
|
2416363b297b2ef4361b845831d5320e39135b69
|
refs/heads/master
| 2020-05-22T13:50:53.644559
| 2016-11-14T02:43:44
| 2016-11-14T02:43:44
| 42,523,930
| 2
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 788
|
java
|
package com.shma.graph;
import java.lang.reflect.Array;
public class Queue<T> {
private T[] array;
private int element;
private int head;
private int tail;
public Queue(Class<?> clazz, int size) {
array = (T[]) Array.newInstance(clazz, size);
head = 0;
tail = -1;
element = 0;
}
public void insert(T value) {
if(tail == array.length - 1) {
tail = -1;
}
array[++tail] = value;
element++;
}
public T remove() {
if(head == array.length) {
head = 0;
}
element--;
return array[head++];
}
public T peek() {
return array[head];
}
public boolean isFull() {
return element >= array.length ? true : false;
}
public boolean isEmpty() {
return element <= 0 ? true : false;
}
}
|
[
"616059480@qq.com"
] |
616059480@qq.com
|
e8e10c8c4b3e84df59223ee4b415774bc7e5d01e
|
0d681cc3e93e75b713937beb409b48ecf423e137
|
/hw08-0036479615/src/main/java/hr/fer/zemris/optjava/dz8/nn/IdentityFunction.java
|
a76b419d70e82b8185c0a22ba0990079a213e4e1
|
[] |
no_license
|
svennjegac/FER-java-optjava
|
fe86ead9bd80b4ef23944ef9234909353673eaab
|
89d9aa124e2e2e32b0f8f1ba09157f03ecd117c6
|
refs/heads/master
| 2020-03-29T04:17:20.952593
| 2018-09-20T08:59:01
| 2018-09-20T08:59:01
| 149,524,350
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 174
|
java
|
package hr.fer.zemris.optjava.dz8.nn;
public class IdentityFunction implements IActivationFunction {
@Override
public double valueAt(double input) {
return input;
}
}
|
[
"sven.njegac@fer.hr"
] |
sven.njegac@fer.hr
|
94c949e491a7b64ec59ee350478089c2f034d2c9
|
fc875ae0713344a52ba5b86013fba0ec8e63748b
|
/app/src/main/java/com/future/zhh/ticket/domain/interactor/CheckLogDetail.java
|
238de5a3e68c5712e469297b0d6a3bf763dc9b8f
|
[] |
no_license
|
zhaohuanhui/Ticket
|
86f01b6392b78c4c50abc68940657368528605aa
|
aa2f72513981a387c6c2579329c8906847398595
|
refs/heads/master
| 2021-10-07T19:54:33.157338
| 2018-11-22T14:01:14
| 2018-11-22T14:01:14
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,102
|
java
|
package com.future.zhh.ticket.domain.interactor;
import com.future.zhh.ticket.data.repository.CommonRepository;
import com.future.zhh.ticket.domain.executor.PostExecutionThread;
import com.future.zhh.ticket.domain.executor.ThreadExecutor;
import com.future.zhh.ticket.domain.interactor.base.Case;
import javax.inject.Inject;
import rx.Observable;
/**
* Created by Administrator on 2017/12/12.
*/
public class CheckLogDetail extends Case {
private CommonRepository repository;
private String customerName;
private String customerID;
@Inject
public CheckLogDetail(ThreadExecutor threadExecutor, PostExecutionThread postExecutionThread,
CommonRepository repository) {
super(threadExecutor, postExecutionThread);
this.repository=repository;
}
public void setData(String customerName,String customerID){
this.customerName=customerName;
this.customerID=customerID;
}
@Override
protected Observable buildCaseObservable() {
return repository.checkLogDetail(customerName,customerID);
}
}
|
[
"you@example.com"
] |
you@example.com
|
003391e5ee9be573ace802e91ca6e2908048d3f3
|
e098f59c8349a59515ffdbf6246df8d11565f016
|
/LeetCode/378. Kth smallest element in sorted matrix/Solution.java
|
604939b40105e22e81b73c2fea24096dbb48ce45
|
[] |
no_license
|
Tubbz-alt/DataStructures_Algorithms
|
af2a80befd2fab3d5f1f910ec0673e3337e79b12
|
d67e5139255e40d524889a13ca75907d169a98a4
|
refs/heads/master
| 2023-02-26T13:23:13.296178
| 2021-02-01T20:18:52
| 2021-02-01T20:18:52
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,093
|
java
|
/**
* Given a n x n matrix where each of the rows and columns are sorted in ascending order, find the kth smallest element in the matrix.
*
* Note that it is the kth smallest element in the sorted order, not the kth distinct element.
*
* Example:
* matrix = [
* [ 1, 5, 9],
* [10, 11, 13],
* [12, 13, 15]
* ],
* k = 8,
*
* return 13.
*
* Note:
* You may assume k is always valid, 1 ≤ k ≤ n2.
*/
/**
* ALGORITHM:
1. Build a minHeap of elements from the first row.
2. Do the following operations k-1 times :
a) Every time when you poll out the root(Top Element in Heap), you need to know the row number and column number of that element
(so we can create a tuple class here),
b) Replace that root with the next element from the same column.
*/
class Solution {
public int kthSmallest(int[][] matrix, int k) {
// Base Condition
if(matrix == null || matrix.length == 0 || matrix[0].length == 0)
return -1;
PriorityQueue<Pair> minHeap = new PriorityQueue<>((a, b) -> (a.val - b.val));
int row = matrix.length;
// Add the elements of the first row
for(int col = 0; col < matrix[0].length; col++) {
minHeap.offer(new Pair(0, col, matrix[0][col]));
}
// Now loop k-1 times, as the first row is already added.
for(int i = 0; i < k - 1; i++) {
// pop out an element from the minHeap.
// insert corresponding next element in that row.
Pair temp = minHeap.poll();
// check if it's the last row. Then don't do anything.
if(temp.row == matrix.length - 1)
continue;
minHeap.offer(new Pair(temp.row + 1, temp.col, matrix[temp.row + 1][temp.col]));
}
return minHeap.poll().val;
}
}
class Pair {
int row;
int col;
int val;
Pair(int row, int col, int val) {
this.row = row;
this.col = col;
this.val = val;
}
}
|
[
"kals9seals@gmail.com"
] |
kals9seals@gmail.com
|
1f416f708f88971db96a903d2aee68762604eb83
|
e26fceb0c49ca5865fcf36bd161a168530ae4e69
|
/OpenAMASE/lib/Flexdock/flexdock-1.2/src/java/perspective/org/flexdock/perspective/event/PerspectiveListener.java
|
c3bca2c3049fc3b56108d939cb26173b59272a5a
|
[
"LicenseRef-scancode-unknown-license-reference",
"LicenseRef-scancode-us-govt-public-domain",
"MIT",
"Apache-2.0",
"LicenseRef-scancode-warranty-disclaimer"
] |
permissive
|
sahabi/OpenAMASE
|
e1ddd2c62848f0046787acbb02b8d31de2f03146
|
b50f5a71265a1f1644c49cce2161b40b108c65fe
|
refs/heads/master
| 2021-06-17T14:15:16.366053
| 2017-05-07T13:16:35
| 2017-05-07T13:16:35
| 90,772,724
| 3
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 945
|
java
|
// ===============================================================================
// Authors: AFRL/RQQD
// Organization: Air Force Research Laboratory, Aerospace Systems Directorate, Power and Control Division
//
// Copyright (c) 2017 Government of the United State of America, as represented by
// the Secretary of the Air Force. No copyright is claimed in the United States under
// Title 17, U.S. Code. All Other Rights Reserved.
// ===============================================================================
/*
* Created on 2005-03-24
*
* TODO To change the template for this generated file go to
* Window - Preferences - Java - Code Style - Code Templates
*/
package org.flexdock.perspective.event;
import java.util.EventListener;
/**
* @author mateusz
*/
public interface PerspectiveListener extends EventListener {
void perspectiveChanged(PerspectiveEvent evt);
void perspectiveReset(PerspectiveEvent evt);
}
|
[
"derek.kingston@us.af.mil"
] |
derek.kingston@us.af.mil
|
ac3655cb7d431694284117f0c30462e1788b3bc0
|
d6920bff5730bf8823315e15b0858c68a91db544
|
/android/ftsafe_0.7.04_source_from_jdcore/gnu/kawa/functions/LispRepositionFormat.java
|
d4554cbe9480e0df62f7b0ddd87040aa7974a2f6
|
[] |
no_license
|
AppWerft/Ti.FeitianSmartcardReader
|
f862f9a2a01e1d2f71e09794aa8ff5e28264e458
|
48657e262044be3ae8b395065d814e169bd8ad7d
|
refs/heads/master
| 2020-05-09T10:54:56.278195
| 2020-03-17T08:04:07
| 2020-03-17T08:04:07
| 181,058,540
| 2
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,855
|
java
|
package gnu.kawa.functions;
import gnu.kawa.format.ReportFormat;
import java.io.IOException;
import java.text.FieldPosition;
class LispRepositionFormat
extends ReportFormat
{
boolean backwards;
boolean absolute;
int count;
public LispRepositionFormat(int count, boolean backwards, boolean absolute)
{
this.count = count;
this.backwards = backwards;
this.absolute = absolute;
}
public int format(Object[] args, int start, Appendable dst, FieldPosition fpos)
throws IOException
{
int count = getParam(this.count, absolute ? 0 : 1, args, start);
if (!absolute)
{
if (backwards)
count = -count;
count += start;
}
return count > args.length ? args.length : count < 0 ? 0 : count;
}
}
|
[
"“rs@hamburger-appwerft.de“"
] |
“rs@hamburger-appwerft.de“
|
ed34132b33f9e300967a094d9dff6e2099e28e78
|
2240677b7236c8c7ad160ae8850072ae91ea9fa6
|
/cdi-osgi/src/main/java/org/apache/aries/cdi/impl/osgi/support/ParameterizedTypeImpl.java
|
cf00640b643bc50643e31c2708dfe334649a50de
|
[] |
no_license
|
gnodet/aries-cdi
|
9594f5999d75d4706fba58fe5ef1e04cd0e8ce26
|
605b613867d56bea102e9c8a94bb00a33570f6d2
|
refs/heads/master
| 2021-01-01T04:30:18.561997
| 2016-05-04T15:43:12
| 2016-05-04T15:43:12
| 56,662,598
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,637
|
java
|
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.apache.aries.cdi.impl.osgi.support;
import java.lang.reflect.ParameterizedType;
import java.lang.reflect.Type;
/**
* ParameterizedType implementation
*/
public class ParameterizedTypeImpl implements ParameterizedType {
private final Type ownerType;
private final Type rawType;
private final Type[] actualTypeArguments;
public ParameterizedTypeImpl(Type ownerType, Type rawType, Type... actualTypeArguments) {
this.ownerType = ownerType;
this.rawType = rawType;
this.actualTypeArguments = actualTypeArguments;
}
@Override
public Type getOwnerType() {
return ownerType;
}
@Override
public Type getRawType() {
return rawType;
}
@Override
public Type[] getActualTypeArguments() {
return actualTypeArguments;
}
}
|
[
"gnodet@apache.org"
] |
gnodet@apache.org
|
66c8e7c77dee8dd3ea30a902ea2f7ec7d5a46909
|
479d9471a522e64f9d12eef6dec15558c8ee82cd
|
/android/helloworld/network/src/main/java/com/example/network/util/Utils.java
|
b55f77e69cb22c89a2a42ea4682798e2fb8c2c26
|
[
"MIT"
] |
permissive
|
mario2100/Spring_All
|
fd76f6b9cca2276d1c308f7d9167930a304dcaf5
|
e32a74293926a5110f7329af5d3d2c0e4f7ad2a5
|
refs/heads/master
| 2023-08-27T17:07:43.238356
| 2021-11-05T06:54:07
| 2021-11-05T06:54:07
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,987
|
java
|
package com.example.network.util;
import android.content.Context;
import android.telephony.TelephonyManager;
import java.io.File;
import java.lang.reflect.Method;
import java.text.DecimalFormat;
public class Utils {
public static String getDotOne(double src) {
DecimalFormat df = new DecimalFormat(".0");
return df.format(src);
}
public static String[] mClassNameArray = {"UNKNOWN", "2G", "3G", "4G"};
// public static int TYPE_UNKNOWN = 0;
// public static int TYPE_2G = 1;
// public static int TYPE_3G = 2;
// public static int TYPE_4G = 3;
//
// public static int TYPE_GSM = 1;
// public static int TYPE_CDMA = 2;
// public static int TYPE_LTE = 3;
// public static int TYPE_WCDMA = 4;
// 获取网络类型的名称
public static String getNetworkTypeName(TelephonyManager tm, int mobile_type) {
String type_name = "";
try {
Method method = tm.getClass().getMethod("getNetworkTypeName", Integer.TYPE);
type_name = (String) method.invoke(tm, mobile_type);
} catch (Exception e) {
e.printStackTrace();
}
return type_name;
}
// 获取网络分代的类型
public static int getClassType(TelephonyManager tm, int mobile_type) {
int class_type = 0;
try {
Method method = tm.getClass().getMethod("getNetworkClass", Integer.TYPE);
class_type = (Integer) method.invoke(tm, mobile_type);
} catch (Exception e) {
e.printStackTrace();
}
return class_type;
}
// 获取网络分代的名称
public static String getClassName(TelephonyManager tm, int mobile_type) {
int class_type = getClassType(tm, mobile_type);
return mClassNameArray[class_type];
}
// 获得指定文件的大小
public static String getFileSize(String file_path) {
File file = new File(file_path);
long size_length = 0;
if (file.exists()) {
size_length = file.length();
}
String size = size_length + "B";
if (size_length > 1024 * 1024) {
size = getDotOne(size_length / 1024.0 / 1024.0) + "MB";
} else if (size_length > 1024) {
size = getDotOne(size_length / 1024.0) + "KB";
}
return size;
}
// 根据手机的分辨率从 dp 的单位 转成为 px(像素)
public static int dip2px(Context context, float dpValue) {
// 获取当前手机的像素密度
final float scale = context.getResources().getDisplayMetrics().density;
return (int) (dpValue * scale + 0.5f); // 四舍五入取整
}
// 根据手机的分辨率从 px(像素) 的单位 转成为 dp
public static int px2dip(Context context, float pxValue) {
// 获取当前手机的像素密度
final float scale = context.getResources().getDisplayMetrics().density;
return (int) (pxValue / scale + 0.5f); // 四舍五入取整
}
}
|
[
"jjh_steed@163.com"
] |
jjh_steed@163.com
|
f908e0e93b2bd42515d465a0d8912e13e27af0bc
|
3f845730d07e3e1f847dc285905e77a132d6edcc
|
/src/main/java/memento/ejercicio/Tarea11/Client.java
|
80edab5a8b0aaeaaeb331cc8cfc569e98efa2659
|
[] |
no_license
|
AleChirinos/Todo-DP
|
2d4911e2910e8f7a2418cd81004352337659c16c
|
c076cb66c9eb5395c8448081249585e53f892ef4
|
refs/heads/main
| 2023-06-08T14:19:18.364102
| 2021-07-01T06:12:10
| 2021-07-01T06:12:10
| 372,260,222
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,698
|
java
|
package memento.ejercicio.Tarea11;
import java.util.LinkedList;
import java.util.List;
public class Client {
public static void main (String []argsss ){
DataBase dataBase = new DataBase();
Originator originator = new Originator();
Person person1 = new Person("Jose", 1345676, 18);
Person person2 = new Person("Angel", 2432567, 20);
Person person3 = new Person("Victoria", 2455333, 22);
Person person4 = new Person("Teresa", 4522536, 24);
Person person5 = new Person("Antonio", 2341127, 21);
Person person6 = new Person("Maria", 4566328, 23);
Person person7 = new Person("David", 1245661, 25);
Person person8 = new Person("Juan", 1155432, 20);
Person person9 = new Person("Javier", 1673323, 23);
Person person10 = new Person("Lucia", 5433216, 27);
Person person11 = new Person("Carlos", 1765547, 28);
Person person12= new Person("Sara", 1987668, 30);
Person person13 = new Person("Rafael", 2457761, 20);
Person person14 = new Person("Pedro", 6433522, 21);
Person person15 = new Person("Paula", 2435673, 18);
List<Person> list1 = new LinkedList<Person>();
list1.add(person1);
list1.add(person2);
list1.add(person3);
List<Person> list2 = new LinkedList<Person>();
list2.add(person4);
list2.add(person5);
list2.add(person6);
List<Person> list3 = new LinkedList<Person>();
list3.add(person7);
list3.add(person8);
list3.add(person9);
List<Person> list4 = new LinkedList<Person>();
list4.add(person10);
list4.add(person11);
list4.add(person12);
List<Person> list5 = new LinkedList<Person>();
list5.add(person13);
list5.add(person14);
list5.add(person15);
BackUplist backUp;
backUp= new BackUplist("BackupMarzo", list1);
originator.setState(backUp);
dataBase.addBackup(originator.createBackUp());
backUp= new BackUplist("BackupMayo", list2);
originator.setState(backUp);
dataBase.addBackup(originator.createBackUp());
backUp= new BackUplist("BackupJulio", list3);
originator.setState(backUp);
dataBase.addBackup(originator.createBackUp());
backUp= new BackUplist("BackupSeptiembre", list4);
originator.setState(backUp);
dataBase.addBackup(originator.createBackUp());
backUp= new BackUplist("BackupNoviembre", list5);
originator.setState(backUp);
dataBase.addBackup(originator.createBackUp());
originator.restoreFromMemento(dataBase.getMemento(1));
}
}
|
[
"alejandra.chirinos2702@gmail.com"
] |
alejandra.chirinos2702@gmail.com
|
77da07e9eda286a0ede0ed5eb94da04da0881913
|
0b1375b80670c1ccbfccbbda0a8a14f61eda00f9
|
/src/test/java/org/realityforge/jeo/geolatte/jpa/mssql/MsLinearRingEntity.java
|
b35e19aeff1b09a4e66b8ffd3bdb2293cc6dc357
|
[
"Apache-2.0"
] |
permissive
|
realityforge/geolatte-geom-jpa
|
cd244409e0d9689cd21f6a36d0fbdd24cdf4baf8
|
77560cbac48458df7b093713693bf57fe5ed8d49
|
refs/heads/master
| 2022-05-03T22:24:25.899314
| 2022-04-29T05:08:02
| 2022-04-29T05:08:02
| 17,855,618
| 4
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 813
|
java
|
package org.realityforge.jeo.geolatte.jpa.mssql;
import java.io.Serializable;
import javax.persistence.Column;
import javax.persistence.Convert;
import javax.persistence.Entity;
import javax.persistence.Id;
import org.geolatte.geom.LinearRing;
import org.realityforge.jeo.geolatte.jpa.SqlServerConverter;
@Entity
public class MsLinearRingEntity
implements Serializable
{
@Id
@Column( name = "id" )
private Integer _id;
@Column( name = "geom", columnDefinition = "GEOMETRY" )
@Convert( converter = SqlServerConverter.class )
private LinearRing _geom;
public Integer getId()
{
return _id;
}
public void setId( final Integer id )
{
_id = id;
}
public LinearRing getGeom()
{
return _geom;
}
public void setGeom( final LinearRing geom )
{
_geom = geom;
}
}
|
[
"peter@realityforge.org"
] |
peter@realityforge.org
|
373a4719fe96401a1055693f88ebd325cb54a260
|
61015130e923c9ec6cedb9936278ac25e26d264e
|
/consul-consumer/src/main/java/com/example/demo/EurekaConsumerApplication.java
|
510ccd64042736cb071dad85e87f1b540febe56f
|
[] |
no_license
|
zhangrunxing/spring-cloud-demo
|
e7e70b09f36a4933206fb38571c58694d5953638
|
e81b19c578e4b2b92d4f0ff2a96920089e0df9c7
|
refs/heads/master
| 2021-06-28T12:18:22.657636
| 2017-09-08T04:14:41
| 2017-09-08T04:14:41
| 103,112,251
| 1
| 0
| null | 2017-09-11T08:49:36
| 2017-09-11T08:49:36
| null |
UTF-8
|
Java
| false
| false
| 602
|
java
|
package com.example.demo;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.web.client.RestTemplate;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
@EnableDiscoveryClient
@SpringBootApplication
public class EurekaConsumerApplication {
@Bean
public RestTemplate restTemplate() {
return new RestTemplate();
}
public static void main(String[] args) {
SpringApplication.run(EurekaConsumerApplication.class, args);
}
}
|
[
"jiaozhiguang@126.com"
] |
jiaozhiguang@126.com
|
37f13c7f67a60082903800ce7623df9864e5a4b7
|
1fa4232de14778f229fdc977acb66ce054756dd2
|
/src/specifique/Vivant.java
|
412b1c9666c97eac6049ab5234bf3c6ef84804d9
|
[] |
no_license
|
dadou666/Lg
|
cba19f0dead92f103cb0565848ee8d8fbc894309
|
fc47e60835d1f55651906668f8b73a462f3bdfa1
|
refs/heads/master
| 2021-04-30T12:14:47.825591
| 2018-06-30T12:52:46
| 2018-06-30T12:52:46
| 121,270,591
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 246
|
java
|
package specifique;
public class Vivant extends vue.ObjetMobile {
public long race;
public long energie;
public long vitesse;
public long vie;
public long puissance;
public long vision;
public long transport;
public long distance;
}
|
[
"david.besnard666@gmail.com"
] |
david.besnard666@gmail.com
|
3197592fdd77ee76875070beb75f4d662bf7bf01
|
8d3dcf19deb7f9869c6c05976418add7b4af179c
|
/app-wanda-credit-ds/src/test/java/com/wanda/credit/ds/test/TestXYanRequestor.java
|
7b3ce6ca5b31f1cd4a66dd6cde94bbe48ef22a62
|
[] |
no_license
|
jianyking/credit-core
|
87fb22f1146303fa2a64e3f9519ca6231a4a452d
|
c0ba2a95919828bb0a55cb5f76c81418e6d38951
|
refs/heads/master
| 2022-04-07T05:41:19.684089
| 2020-02-14T05:29:10
| 2020-02-14T05:29:10
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,601
|
java
|
package com.wanda.credit.ds.test;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import javax.annotation.Resource;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import com.alibaba.fastjson.JSONObject;
import com.wanda.credit.api.dto.DataSource;
import com.wanda.credit.api.dto.Param;
import com.wanda.credit.base.util.StringUtil;
import com.wanda.credit.ds.client.xyan.XYanIdcardCheckSourceRequestor;
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = "classpath:spring.xml")
public class TestXYanRequestor {
@Resource(name="ds_xyan_police")
private XYanIdcardCheckSourceRequestor aijinService;
final static String ds_id = "ds_xyan_police";
@Test
public void test() throws Exception {
DataSource ds =new DataSource();
ds.setId(ds_id);
ds.setRefProdCode("P_C_B001");
List<Param> params_in = new ArrayList<Param>();
Param p1 = new Param();
Param p2 = new Param();
Param p3 = new Param();
p1.setId("name");
p1.setValue("韩宝欣");
p2.setId("cardNo");
p2.setValue("320911198501112510");
p3.setId("flag");
p3.setValue("01");
params_in.add(p1);
params_in.add(p2);
ds.setParams_in(params_in);
System.out.println("请求信息:\n"+JSONObject.toJSONString(ds, true));
Map<String,Object> ret = aijinService.request(StringUtil.getRandomNo(), ds);
System.out.println("返回消息为:\n"+JSONObject.toJSONString(ret, true));
}
}
|
[
"liunan1944@163.com"
] |
liunan1944@163.com
|
1dab0a6d36c0a28da63d349f603a0e5b955772b8
|
363c936f4a89b7d3f5f4fb588e8ca20c527f6022
|
/AL-Game/data/scripts/system/handlers/quest/esoterrace/_28409GroupMaketheBladeComplete.java
|
4df978b259b549ece0be3783cb35a3cffaabf060
|
[] |
no_license
|
G-Robson26/AionServer-4.9F
|
d628ccb4307aa0589a70b293b311422019088858
|
3376c78b8d90bd4d859a7cfc25c5edc775e51cbf
|
refs/heads/master
| 2023-09-04T00:46:47.954822
| 2017-08-09T13:23:03
| 2017-08-09T13:23:03
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,793
|
java
|
/**
* This file is part of Aion-Lightning <aion-lightning.org>.
*
* Aion-Lightning is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Aion-Lightning is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details. *
* You should have received a copy of the GNU General Public License
* along with Aion-Lightning.
* If not, see <http://www.gnu.org/licenses/>.
*/
package quest.esoterrace;
import java.util.Collections;
import com.aionemu.gameserver.model.gameobjects.player.Player;
import com.aionemu.gameserver.model.templates.quest.QuestItems;
import com.aionemu.gameserver.questEngine.handlers.QuestHandler;
import com.aionemu.gameserver.model.DialogAction;
import com.aionemu.gameserver.questEngine.model.QuestEnv;
import com.aionemu.gameserver.questEngine.model.QuestState;
import com.aionemu.gameserver.questEngine.model.QuestStatus;
import com.aionemu.gameserver.services.item.ItemService;
/**
* @author Ritsu
*
*/
public class _28409GroupMaketheBladeComplete extends QuestHandler {
private final static int questId = 28409;
public _28409GroupMaketheBladeComplete() {
super(questId);
}
@Override
public void register() {
qe.registerQuestNpc(799558).addOnQuestStart(questId);
qe.registerQuestNpc(799558).addOnTalkEvent(questId);
qe.registerQuestNpc(799557).addOnTalkEvent(questId);
qe.registerQuestNpc(205237).addOnTalkEvent(questId);
qe.registerQuestNpc(215795).addOnKillEvent(questId);
}
@Override
public boolean onDialogEvent(QuestEnv env) {
Player player = env.getPlayer();
int targetId = env.getTargetId();
QuestState qs = player.getQuestStateList().getQuestState(questId);
if (targetId == 799558) {
if (qs == null || qs.getStatus() == QuestStatus.NONE) {
if (env.getDialog() == DialogAction.QUEST_SELECT) {
return sendQuestDialog(env, 4762);
} else {
return sendQuestStartDialog(env);
}
}
} else if (targetId == 799557) {
if (qs != null && qs.getStatus() == QuestStatus.START && qs.getQuestVarById(0) == 0) {
if (env.getDialog() == DialogAction.QUEST_SELECT) {
return sendQuestDialog(env, 1011);
} else if (env.getDialog() == DialogAction.SETPRO1) {
return defaultCloseDialog(env, 0, 1);
} else {
return sendQuestStartDialog(env);
}
} else if (qs != null && qs.getStatus() == QuestStatus.REWARD) {
if (env.getDialog() == DialogAction.USE_OBJECT) {
return sendQuestDialog(env, 10002);
} else if (env.getDialog() == DialogAction.SELECT_QUEST_REWARD) {
return sendQuestDialog(env, 5);
} else {
return sendQuestEndDialog(env);
}
}
} else if (targetId == 205237) {
if (qs != null && qs.getStatus() == QuestStatus.START && qs.getQuestVarById(0) == 1) {
if (env.getDialog() == DialogAction.QUEST_SELECT) {
return sendQuestDialog(env, 1352);
} else if (env.getDialog() == DialogAction.SETPRO2) {
return defaultCloseDialog(env, 1, 2, 182215007, 1, 182215006, 1);
} else {
return sendQuestStartDialog(env);
}
}
}
return false;
}
@Override
public boolean onKillEvent(QuestEnv env) {
Player player = env.getPlayer();
QuestState qs = player.getQuestStateList().getQuestState(questId);
if (qs == null || qs.getStatus() != QuestStatus.START) {
return false;
}
int targetId = env.getTargetId();
switch (targetId) {
case 215795:
if (qs.getQuestVarById(0) == 2) {
ItemService.addQuestItems(player, Collections.singletonList(new QuestItems(182215008, 1)));
player.getInventory().decreaseByItemId(182215007, 1);
qs.setStatus(QuestStatus.REWARD);
updateQuestStatus(env);
}
}
return false;
}
}
|
[
"falke34@a70f7278-c47d-401d-a0e4-c9401b7f63ed"
] |
falke34@a70f7278-c47d-401d-a0e4-c9401b7f63ed
|
2dabd67f63766ae216e209d1ee7078e1fdeccd24
|
9ed0856b702d193f20eecac15a1fe9f39adbeaea
|
/src/main/java/ch/hotela/affiliate/config/SecurityConfiguration.java
|
25cf3cf1842220120a3d62b0613da20cf12a3157
|
[] |
no_license
|
yassineLajmi/ehotela-affiliate-application
|
77095052efc10184ef9769be8c3d0d2798736ffe
|
c693d9f33806534948ab4f2ef6c812d1e53a4576
|
refs/heads/master
| 2021-07-05T08:02:00.651325
| 2019-04-10T09:24:40
| 2019-04-10T09:24:40
| 180,305,160
| 0
| 1
| null | 2020-09-18T14:26:46
| 2019-04-09T07:00:55
|
Java
|
UTF-8
|
Java
| false
| false
| 4,967
|
java
|
package ch.hotela.affiliate.config;
import ch.hotela.affiliate.security.*;
import ch.hotela.affiliate.security.jwt.*;
import org.springframework.beans.factory.BeanInitializationException;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Import;
import org.springframework.http.HttpMethod;
import org.springframework.security.authentication.AuthenticationManager;
import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder;
import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.builders.WebSecurity;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
import org.springframework.security.config.http.SessionCreationPolicy;
import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
import org.springframework.security.crypto.password.PasswordEncoder;
import org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter;
import org.springframework.web.filter.CorsFilter;
import org.zalando.problem.spring.web.advice.security.SecurityProblemSupport;
import javax.annotation.PostConstruct;
@Configuration
@EnableWebSecurity
@EnableGlobalMethodSecurity(prePostEnabled = true, securedEnabled = true)
@Import(SecurityProblemSupport.class)
public class SecurityConfiguration extends WebSecurityConfigurerAdapter {
private final AuthenticationManagerBuilder authenticationManagerBuilder;
private final UserDetailsService userDetailsService;
private final TokenProvider tokenProvider;
private final CorsFilter corsFilter;
private final SecurityProblemSupport problemSupport;
public SecurityConfiguration(AuthenticationManagerBuilder authenticationManagerBuilder, UserDetailsService userDetailsService, TokenProvider tokenProvider, CorsFilter corsFilter, SecurityProblemSupport problemSupport) {
this.authenticationManagerBuilder = authenticationManagerBuilder;
this.userDetailsService = userDetailsService;
this.tokenProvider = tokenProvider;
this.corsFilter = corsFilter;
this.problemSupport = problemSupport;
}
@PostConstruct
public void init() {
try {
authenticationManagerBuilder
.userDetailsService(userDetailsService)
.passwordEncoder(passwordEncoder());
} catch (Exception e) {
throw new BeanInitializationException("Security configuration failed", e);
}
}
@Override
@Bean
public AuthenticationManager authenticationManagerBean() throws Exception {
return super.authenticationManagerBean();
}
@Bean
public PasswordEncoder passwordEncoder() {
return new BCryptPasswordEncoder();
}
@Override
public void configure(WebSecurity web) throws Exception {
web.ignoring()
.antMatchers(HttpMethod.OPTIONS, "/**")
.antMatchers("/app/**/*.{js,html}")
.antMatchers("/i18n/**")
.antMatchers("/content/**")
.antMatchers("/h2-console/**")
.antMatchers("/swagger-ui/index.html")
.antMatchers("/test/**");
}
@Override
public void configure(HttpSecurity http) throws Exception {
http
.csrf()
.disable()
.addFilterBefore(corsFilter, UsernamePasswordAuthenticationFilter.class)
.exceptionHandling()
.authenticationEntryPoint(problemSupport)
.accessDeniedHandler(problemSupport)
.and()
.headers()
.frameOptions()
.disable()
.and()
.sessionManagement()
.sessionCreationPolicy(SessionCreationPolicy.STATELESS)
.and()
.authorizeRequests()
.antMatchers("/api/register").permitAll()
.antMatchers("/api/activate").permitAll()
.antMatchers("/api/authenticate").permitAll()
.antMatchers("/api/account/reset-password/init").permitAll()
.antMatchers("/api/account/reset-password/finish").permitAll()
.antMatchers("/api/**").authenticated()
.antMatchers("/management/health").permitAll()
.antMatchers("/management/info").permitAll()
.antMatchers("/management/**").hasAuthority(AuthoritiesConstants.ADMIN)
.and()
.apply(securityConfigurerAdapter());
}
private JWTConfigurer securityConfigurerAdapter() {
return new JWTConfigurer(tokenProvider);
}
}
|
[
"jhipster-bot@jhipster.tech"
] |
jhipster-bot@jhipster.tech
|
0e8ff503dae7df4a26980450b9e2160121a24b90
|
56ae790ef1b0a65643a5e8c7e14a6f5d2e88cbdd
|
/patrimonio/src/main/java/com/t2tierp/model/bean/patrimonio/Seguradora.java
|
c795aa44eebcb4422dc7d04497a10acce497aef7
|
[
"MIT"
] |
permissive
|
herculeshssj/T2Ti-ERP-2.0-Java-WEB
|
6751db19b82954116f855fe107c4ac188524d7d5
|
275205e05a0522a2ba9c36d36ba577230e083e72
|
refs/heads/master
| 2023-01-04T21:06:24.175662
| 2020-10-30T11:00:46
| 2020-10-30T11:00:46
| 286,570,333
| 0
| 0
| null | 2020-08-10T20:16:56
| 2020-08-10T20:16:56
| null |
UTF-8
|
Java
| false
| false
| 3,126
|
java
|
/*
* The MIT License
*
* Copyright: Copyright (C) 2014 T2Ti.COM
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*
* The author may be contacted at: t2ti.com@gmail.com
*
* @author Claudio de Barros (T2Ti.com)
* @version 2.0
*/
package com.t2tierp.model.bean.patrimonio;
import com.t2tierp.model.bean.cadastros.Empresa;
import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
@Entity
@Table(name = "SEGURADORA")
public class Seguradora implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue(strategy = GenerationType.IDENTITY)
@Basic(optional = false)
@Column(name = "ID")
private Integer id;
@Column(name = "NOME")
private String nome;
@Column(name = "CONTATO")
private String contato;
@Column(name = "TELEFONE")
private String telefone;
@JoinColumn(name = "ID_EMPRESA", referencedColumnName = "ID")
@ManyToOne(optional = false)
private Empresa empresa;
public Seguradora() {
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getNome() {
return nome;
}
public void setNome(String nome) {
this.nome = nome;
}
public String getContato() {
return contato;
}
public void setContato(String contato) {
this.contato = contato;
}
public String getTelefone() {
return telefone;
}
public void setTelefone(String telefone) {
this.telefone = telefone;
}
public Empresa getEmpresa() {
return empresa;
}
public void setEmpresa(Empresa empresa) {
this.empresa = empresa;
}
@Override
public String toString() {
return "com.t2tierp.model.bean.patrimonio.Seguradora[id=" + id + "]";
}
}
|
[
"claudiobsi@gmail.com"
] |
claudiobsi@gmail.com
|
948a76daa7aee1f24c57f7fbe6ff52ab105ba536
|
1d928c3f90d4a0a9a3919a804597aa0a4aab19a3
|
/java/neo4j/2016/4/QueryExecutionEvent.java
|
51430e9c10b4d4d7f6c7ef4a9e19a54de383a07f
|
[] |
no_license
|
rosoareslv/SED99
|
d8b2ff5811e7f0ffc59be066a5a0349a92cbb845
|
a062c118f12b93172e31e8ca115ce3f871b64461
|
refs/heads/main
| 2023-02-22T21:59:02.703005
| 2021-01-28T19:40:51
| 2021-01-28T19:40:51
| 306,497,459
| 1
| 1
| null | 2020-11-24T20:56:18
| 2020-10-23T01:18:07
| null |
UTF-8
|
Java
| false
| false
| 1,254
|
java
|
/*
* Copyright (c) 2002-2016 "Neo Technology,"
* Network Engine for Objects in Lund AB [http://neotechnology.com]
*
* This file is part of Neo4j.
*
* Neo4j is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package org.neo4j.cypher.internal.compiler.v3_0.codegen;
public interface QueryExecutionEvent extends AutoCloseable
{
void dbHit();
void row();
@Override
void close();
QueryExecutionEvent NONE = new QueryExecutionEvent()
{
@Override
public void dbHit()
{
}
@Override
public void row()
{
}
@Override
public void close()
{
}
};
}
|
[
"rodrigosoaresilva@gmail.com"
] |
rodrigosoaresilva@gmail.com
|
ac8a81aaea09b76fd26be78ba0721e9a3296b75a
|
d94b035cbb5566dc3e1223ea9f576f9cd2f4a5a1
|
/corejavasession/src/com/careerit/cj/day16/Employee.java
|
45d246da2f35e00369d9604e6d8ef9a29a077ec6
|
[] |
no_license
|
learnwithlakshman/java_full_stack_b_4
|
01b07901f4f1ed7eadd982ca9fb056958013dd9d
|
c81a43190a8b4b1c2175389ca046e6f7e087e33a
|
refs/heads/master
| 2022-12-17T04:22:43.137790
| 2020-09-14T03:29:24
| 2020-09-14T03:29:24
| 286,891,743
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 751
|
java
|
package com.careerit.cj.day16;
public class Employee {
private int empno;
private String name;
private String qualification;
private double salary;
public Employee(String name, String qualification) {
this(name, qualification,0);
}
public Employee(String name, String qualification, double salary) {
this(0, name, qualification, salary);
}
public Employee(int empno, String name, String qualification, double salary) {
this.empno = empno;
this.name = name;
this.qualification = qualification;
this.salary = salary;
}
public void showDetails() {
System.out.println(String.format("Empno : %d \nEname : %s \nQualification : %s \nSalary : %f ", empno, name,
qualification, salary));
}
}
|
[
"tanvi.avula@outlook.com"
] |
tanvi.avula@outlook.com
|
3c276aa21624bfa1875c3e33246d3779679bbf7c
|
95ce8e5bd2246e687d5cd590797e661de1899899
|
/RecursivePowers.java
|
9b020558498de22aad909466e81d5406e7f6f7e3
|
[] |
no_license
|
craigtupac-96/Toolbox-Java
|
ddb9cd9a21b9cbe58b4a97b00dc185692c89804d
|
37d5ca2fcd79db36cd57319b6a339b0360b8778e
|
refs/heads/master
| 2021-10-19T20:07:35.529727
| 2019-02-23T10:36:19
| 2019-02-23T10:36:19
| 124,567,149
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 563
|
java
|
/*
* Author: Craig Lawlor
* C00184465
*/
package algorithm;
import java.util.Scanner;
public class RecursivePowers {
public static void main(String[] args) {
int num;
int pow;
Scanner input = new Scanner(System.in);
System.out.println("Enter a number");
num = input.nextInt();
System.out.println("Enter a power");
pow = input.nextInt();
System.out.println(power(num, pow));
input.close();
}
public static int power(int n, int p){
if(p == 1){ // base case
return n;
}
else{
return n * power(n, p-1);
}
}
}
|
[
"you@example.com"
] |
you@example.com
|
dc332e354b2b4fcf16d03c85ff4343f86e45f675
|
fa91450deb625cda070e82d5c31770be5ca1dec6
|
/Diff-Raw-Data/27/27_da0cf904a83e225c7f16090b60f524e1f9241003/UDPBroadcastMessage/27_da0cf904a83e225c7f16090b60f524e1f9241003_UDPBroadcastMessage_s.java
|
6f111c8e2c5d9fa5c45a743220ffdb2149677b2f
|
[] |
no_license
|
zhongxingyu/Seer
|
48e7e5197624d7afa94d23f849f8ea2075bcaec0
|
c11a3109fdfca9be337e509ecb2c085b60076213
|
refs/heads/master
| 2023-07-06T12:48:55.516692
| 2023-06-22T07:55:56
| 2023-06-22T07:55:56
| 259,613,157
| 6
| 2
| null | 2023-06-22T07:55:57
| 2020-04-28T11:07:49
| null |
UTF-8
|
Java
| false
| false
| 2,456
|
java
|
package Messages;
public class UDPBroadcastMessage extends Message {
public String senderUsername=null;
public String targetUsername=null;
public String senderIP=null;
public static final long minSize=260;
public UDPBroadcastMessage(int _op,long _length,long _reserved,String _options,byte[] body){
super(_op,_length,_reserved,_options);
processBody(body);
if(op!=1){
correct=false;
}
}
public UDPBroadcastMessage(int _op,long _length,long _reserved,String _options,String _senderUsername,String _targetUsername,String _senderIP){
super(_op,_length,_reserved,_options);
senderUsername=_senderUsername;
targetUsername= _targetUsername;
senderIP=_senderIP;
if(op!=1){
correct=false;
}
}
private void processBody(byte[] body){
if(body.length!=260){
correct=false;
return;
}
byte [] senderUserArray = new byte[128];
for (int i = 0; i < body.length && i < 128; i++){
senderUserArray[i] = body[i];
}
senderUsername=new String(senderUserArray,0,senderUserArray.length);
byte [] senderIPArray=new byte[]{body[128],body[129],body[130],body[131]};
senderIP=new String(senderIPArray,0,senderIPArray.length);
int offset=132;
byte [] targetUserArray = new byte[128];
for (int i = 0; i < body.length && i < 128; i++){
targetUserArray[i] = body[offset+i];
System.out.println(targetUserArray[128-i-1]);
}
targetUsername=new String(targetUserArray,0,targetUserArray.length);
}
public byte[] convert(){
byte[] upper=super.convert();
byte[] storage=new byte[(int) (upper.length+minSize)];
for(int i=0;i<upper.length;i++){
storage[i]=upper[i];
}
int total=upper.length-1;
byte[] tmp=null;
tmp=senderUsername.getBytes();
for(int i=0;i<tmp.length;i++){
storage[total+i]=tmp[i];
}
total+=128;
tmp=senderIP.getBytes();
for(int i=0;i<tmp.length;i++){
storage[total+i]=tmp[i];
}
total+=4;
tmp=targetUsername.getBytes();
for(int i=0;i<tmp.length;i++){
storage[total+i]=tmp[i];
}
total+=128;
return storage;
}
}
|
[
"yuzhongxing88@gmail.com"
] |
yuzhongxing88@gmail.com
|
d6b280581617faf6cabda8ea97605921797b45ca
|
022980735384919a0e9084f57ea2f495b10c0d12
|
/src/ext-lltnxp/ext-impl/src/com/sgs/portlet/country/pmluserfiletype/service/http/PmlUserFileTypeServiceHttp.java
|
f099bbd062fe7f0c5ee3a723d9a5578af9704462
|
[] |
no_license
|
thaond/nsscttdt
|
474d8e359f899d4ea6f48dd46ccd19bbcf34b73a
|
ae7dacc924efe578ce655ddfc455d10c953abbac
|
refs/heads/master
| 2021-01-10T03:00:24.086974
| 2011-02-19T09:18:34
| 2011-02-19T09:18:34
| 50,081,202
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,452
|
java
|
package com.sgs.portlet.country.pmluserfiletype.service.http;
/**
* <a href="PmlUserFileTypeServiceHttp.java.html"><b><i>View Source</i></b></a>
*
* <p>
* ServiceBuilder generated this class. Modifications in this class will be
* overwritten the next time is generated.
* </p>
*
* <p>
* This class provides a HTTP utility for the
* <code>com.sgs.portlet.country.pmluserfiletype.service.PmlUserFileTypeServiceUtil</code> service
* utility. The static methods of this class calls the same methods of the
* service utility. However, the signatures are different because it requires an
* additional <code>com.liferay.portal.security.auth.HttpPrincipal</code>
* parameter.
* </p>
*
* <p>
* The benefits of using the HTTP utility is that it is fast and allows for
* tunneling without the cost of serializing to text. The drawback is that it
* only works with Java.
* </p>
*
* <p>
* Set the property <code>tunnel.servlet.hosts.allowed</code> in
* portal.properties to configure security.
* </p>
*
* <p>
* The HTTP utility is only generated for remote services.
* </p>
*
* @author Brian Wing Shun Chan
*
* @see com.liferay.portal.security.auth.HttpPrincipal
* @see com.sgs.portlet.country.pmluserfiletype.service.PmlUserFileTypeServiceUtil
* @see com.sgs.portlet.country.pmluserfiletype.service.http.PmlUserFileTypeServiceSoap
*
*/
public class PmlUserFileTypeServiceHttp {
}
|
[
"nguyentanmo@843501e3-6f96-e689-5e61-164601347e4e"
] |
nguyentanmo@843501e3-6f96-e689-5e61-164601347e4e
|
9d3b9fa11aee1da52605cd30fd1036a83b71ace3
|
c5053ca77a4046af3f42ba243fc871292660f386
|
/robospice-core-parent/robospice/src/main/java/com/octo/android/robospice/request/listener/SpiceServiceServiceListener.java
|
e2c08fd2da931a7c6a83217050e0521151c7a09b
|
[
"Apache-2.0"
] |
permissive
|
sarvex/RoboSpice
|
3c4399856230330c2514666878ec9900f44c8b31
|
9b66be3100d04fe8b02cfbe4deaf2adccc0c0c0f
|
refs/heads/release
| 2023-05-12T04:12:33.982495
| 2023-05-01T06:14:16
| 2023-05-01T06:14:16
| 32,646,504
| 0
| 0
|
Apache-2.0
| 2023-09-14T08:24:33
| 2015-03-21T19:23:21
|
Java
|
UTF-8
|
Java
| false
| false
| 480
|
java
|
package com.octo.android.robospice.request.listener;
import java.util.Set;
import com.octo.android.robospice.SpiceService;
import com.octo.android.robospice.request.CachedSpiceRequest;
/**
* Defines the behavior of a listener that will be notified of request
* processing by the {@link SpiceService}.
* @author sni
*/
public interface SpiceServiceServiceListener {
void onRequestProcessed(CachedSpiceRequest<?> cachedSpiceRequest, Set<RequestListener<?>> listeners);
}
|
[
"steff.nicolas@gmail.com"
] |
steff.nicolas@gmail.com
|
4d9abcc124e5594b631b72574e3ec3c73ef02ffc
|
0a9c8d0adbb8048433da7670ea83b51fcaceba31
|
/app/src/main/java/com/idx/launcher/user/personal_center/address/bean/AddAddress.java
|
c0e02e10b86eca7e842698ac73a9a3ba68599135
|
[] |
no_license
|
sqHayden/Launcher
|
9d89bfe9fd7dfd1a3713b5beb4c0fbf82fcafb4a
|
11f9bb5e79525de6f58f4b2849a50ac346c9aa45
|
refs/heads/master
| 2020-03-21T14:47:48.944823
| 2018-06-25T02:09:22
| 2018-06-25T02:09:22
| 138,676,131
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,555
|
java
|
package com.idx.launcher.user.personal_center.address.bean;
import android.text.TextUtils;
import android.util.Log;
import net.imoran.tv.sdk.network.gson.GsonObjectDeserializer;
import net.imoran.tv.sdk.network.param.BaseParams;
import java.util.HashMap;
/**
* 增加地址
* Created by ryan on 18-4-20.
* Email: Ryan_chan01212@yeah.net
*/
public class AddAddress extends BaseParams {
private UserInfoBean userInfoBean;
private String createid;
private String uid;
public AddAddress() {
}
public UserInfoBean getUserInfoBean() {
return userInfoBean;
}
public void setUserInfoBean(UserInfoBean userInfoBean) {
this.userInfoBean = userInfoBean;
}
public String getCreateid() {
return createid;
}
public void setCreateid(String createid) {
this.createid = createid;
}
public String getUuid() {
return uid;
}
public void setUuid(String uid) {
this.uid = uid;
}
@Override
public HashMap<String, String> getParams() {
HashMap<String, String> params = new HashMap();
if(TextUtils.isEmpty(GsonObjectDeserializer.produceGson().toJson(this.getUserInfoBean()))) {
Log.e("params", "RegisterParams getParams empty");
return null;
} else {
params.put("json", GsonObjectDeserializer.produceGson().toJson(this.getUserInfoBean()));
params.put("uid", getUuid());
params.put("createid",getCreateid());
return params;
}
}
}
|
[
"ryan.fp.chan@mail.foxconn.com"
] |
ryan.fp.chan@mail.foxconn.com
|
4c65910ad6f878f154f117e52f94257882613335
|
41ace4588685de5f1e71415ad4e9f3bdf4c6cb1f
|
/src/main/java/com/learnwithted/kidbank/adapter/web/TransactionView.java
|
3261d094225bc823ef2fc99bb8943869466551b1
|
[
"Apache-2.0"
] |
permissive
|
tedyoung/kid-bank
|
43eebaf30e2a6f8ed60613cd7fdf6950cbeb2a59
|
bb6376dffdf021dd6ab22e6224d3be997c1094b9
|
refs/heads/master
| 2023-08-31T22:33:31.929073
| 2022-06-01T23:26:43
| 2022-06-01T23:26:43
| 165,791,269
| 100
| 33
|
Apache-2.0
| 2023-07-07T21:58:02
| 2019-01-15T05:33:29
|
Java
|
UTF-8
|
Java
| false
| false
| 3,873
|
java
|
package com.learnwithted.kidbank.adapter.web;
import com.learnwithted.kidbank.adapter.DateFormatting;
import com.learnwithted.kidbank.adapter.ScaledDecimals;
import com.learnwithted.kidbank.domain.Transaction;
import com.learnwithted.kidbank.domain.UserProfile;
import java.util.Collections;
import java.util.List;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.stream.Collectors;
public class TransactionView {
private final String date;
private final String action;
private final String amount;
private final String runningBalance;
private final String source;
private final String creator;
public TransactionView(String date, String action, String amount, String runningBalance, String source, String creator) {
this.date = date;
this.action = action;
this.amount = amount;
this.runningBalance = runningBalance;
this.source = source;
this.creator = creator;
}
public static TransactionView viewOf(Transaction txn, int runningBalance) {
String amountString = ScaledDecimals.formatAsMoney(txn.amount());
String runningBalanceString = ScaledDecimals.formatAsMoney(runningBalance);
String dateAsString = DateFormatting.formatAsDate(txn.dateTime());
String actionString = ActionFormatter.format(txn.action());
String creatorString = txn.creator()
.map(UserProfile::name)
.orElse("none");
return new TransactionView(dateAsString, actionString, amountString,
runningBalanceString, txn.source(), creatorString);
}
public static List<TransactionView> viewsOf(List<Transaction> transactions) {
AtomicInteger runningBalance = new AtomicInteger(0);
// we stream through these transactions from oldest to newest so that
// accumulating the running balance works correctly
List<TransactionView> views = transactions
.stream()
.peek(transaction -> runningBalance.addAndGet(transaction.signedAmount()))
.map(txn -> viewOf(txn, runningBalance.get()))
.collect(Collectors.toList());
// now reverse the order as incoming transactions were ordered oldest-to-newest
// and we want the display to be newest at the "top" and oldest at the "bottom"
Collections.reverse(views);
return views;
}
public String getDate() {
return this.date;
}
public String getAction() {
return this.action;
}
public String getAmount() {
return this.amount;
}
public String getRunningBalance() {
return runningBalance;
}
public String getSource() {
return this.source;
}
public String getCreator() {
return this.creator;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
TransactionView that = (TransactionView) o;
if (!date.equals(that.date)) return false;
if (!action.equals(that.action)) return false;
if (!amount.equals(that.amount)) return false;
if (!runningBalance.equals(that.runningBalance)) return false;
if (!source.equals(that.source)) return false;
return creator.equals(that.creator);
}
@Override
public int hashCode() {
int result = date.hashCode();
result = 31 * result + action.hashCode();
result = 31 * result + amount.hashCode();
result = 31 * result + runningBalance.hashCode();
result = 31 * result + source.hashCode();
result = 31 * result + creator.hashCode();
return result;
}
@Override
public String toString() {
return "TransactionView{" +
"date='" + date + '\'' +
", action='" + action + '\'' +
", amount='" + amount + '\'' +
", runningBalance='" + runningBalance + '\'' +
", source='" + source + '\'' +
", creator='" + creator + '\'' +
'}';
}
}
|
[
"tedyoung@gmail.com"
] |
tedyoung@gmail.com
|
6fec3a7666548a5ab244030bbd4b03d9ec2f75f8
|
2da39b9c4579c0c27832733b57069680f9a31ab3
|
/src/test/java/gyaxi/kovacseni/zoo/GiraffeTest.java
|
bfbac6b3b11242676a298885b2c19d22779fb81b
|
[] |
no_license
|
exylaci/training-solutions
|
783874ae3f15f19cf183ae0c3f74fb88de53bc51
|
41ce082de1cc6b7bf901931445b6422b4ae8df64
|
refs/heads/master
| 2023-08-05T19:13:27.021645
| 2021-10-13T16:47:23
| 2021-10-13T16:47:23
| 309,077,220
| 1
| 4
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 486
|
java
|
package gyaxi.kovacseni.zoo;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
public class GiraffeTest {
@Test
public void testCreate() {
ZooAnimal giraffe = new Giraffe("Momba", 3);
Assertions.assertEquals("Momba", giraffe.getName());
Assertions.assertEquals(3, giraffe.getLength());
Assertions.assertEquals(0L, giraffe.getWeight());
Assertions.assertEquals(AnimalType.GIRAFFE, giraffe.getType());
}
}
|
[
"exy@freemail.hu"
] |
exy@freemail.hu
|
35e9fff7f207fc400ad3a8d30aa2c182d5dc2866
|
3b91ed788572b6d5ac4db1bee814a74560603578
|
/com/tencent/mm/plugin/wallet_core/ui/view/WalletSuccPageAwardWidget$2.java
|
afd79629ca4a68efd151a7ab7b421d22dfcf0257
|
[] |
no_license
|
linsir6/WeChat_java
|
a1deee3035b555fb35a423f367eb5e3e58a17cb0
|
32e52b88c012051100315af6751111bfb6697a29
|
refs/heads/master
| 2020-05-31T05:40:17.161282
| 2018-08-28T02:07:02
| 2018-08-28T02:07:02
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,082
|
java
|
package com.tencent.mm.plugin.wallet_core.ui.view;
import android.widget.FrameLayout.LayoutParams;
import com.tencent.mm.bp.a;
class WalletSuccPageAwardWidget$2 implements Runnable {
final /* synthetic */ WalletSuccPageAwardWidget pAM;
WalletSuccPageAwardWidget$2(WalletSuccPageAwardWidget walletSuccPageAwardWidget) {
this.pAM = walletSuccPageAwardWidget;
}
public final void run() {
if (WalletSuccPageAwardWidget.d(this.pAM).getHeight() != this.pAM.getHeight()) {
LayoutParams layoutParams = (LayoutParams) WalletSuccPageAwardWidget.d(this.pAM).getLayoutParams();
layoutParams.width = WalletSuccPageAwardWidget.b(this.pAM).getWidth();
layoutParams.height = WalletSuccPageAwardWidget.b(this.pAM).getHeight() - a.fromDPToPix(this.pAM.getContext(), 2);
layoutParams.topMargin = a.fromDPToPix(this.pAM.getContext(), 1);
layoutParams.bottomMargin = a.fromDPToPix(this.pAM.getContext(), 1);
WalletSuccPageAwardWidget.d(this.pAM).setLayoutParams(layoutParams);
}
}
}
|
[
"707194831@qq.com"
] |
707194831@qq.com
|
be006eb685472b936421c406d8c1d9f36125a3e3
|
b6e99b0346572b7def0e9cdd1b03990beb99e26f
|
/src/gcom/gui/arrecadacao/InserirGuiaDevolucaoActionForm.java
|
aaffedc0cdace0ebfe068de060fac92740ce8706
|
[] |
no_license
|
prodigasistemas/gsan
|
ad64782c7bc991329ce5f0bf5491c810e9487d6b
|
bfbf7ad298c3c9646bdf5d9c791e62d7366499c1
|
refs/heads/master
| 2023-08-31T10:47:21.784105
| 2023-08-23T17:53:24
| 2023-08-23T17:53:24
| 14,600,520
| 19
| 20
| null | 2015-07-29T19:39:10
| 2013-11-21T21:24:16
|
Java
|
UTF-8
|
Java
| false
| false
| 7,111
|
java
|
package gcom.gui.arrecadacao;
import javax.servlet.http.HttpServletRequest;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;
public class InserirGuiaDevolucaoActionForm extends ActionForm {
private static final long serialVersionUID = 1L;
private String idRegistroAtendimento;
private String nomeRegistroAtendimento;
private String idOrdemServico;
private String nomeOrdemServico;
private String documentoTipo;
private String documentoTipoHidden;
private String idLocalidade;
private String idLocalidadeHidden;
private String descricaoLocalidade;
private String idImovel;
private String descricaoImovel;
private String codigoCliente;
private String nomeCliente;
private String referenciaConta;
private String descricaoConta;
private String idGuiaPagamento;
private String descricaoGuiaPagamento;
private String valorGuiaPagamento;
private String idDebitoACobrar;
private String descricaoDebitoACobrar;
private String valorDebitoACobrar;
private String idTipoDebito;
private String idTipoDebitoHidden;
private String descricaoTipoDebito;
private String valorDevolucao;
private String idFuncionarioAnalista;
private String nomeFuncionarioAnalista;
private String idFuncionarioAutorizador;
private String nomeFuncionarioAutorizador;
public ActionErrors validate(ActionMapping actionMapping,
HttpServletRequest httpServletRequest) {
/** @todo: finish this method, this is just the skeleton. */
return null;
}
public String getCodigoCliente() {
return codigoCliente;
}
public void setCodigoCliente(String codigoCliente) {
this.codigoCliente = codigoCliente;
}
public String getDescricaoConta() {
return descricaoConta;
}
public void setDescricaoConta(String descricaoConta) {
this.descricaoConta = descricaoConta;
}
public String getDescricaoDebitoACobrar() {
return descricaoDebitoACobrar;
}
public void setDescricaoDebitoACobrar(String descricaoDebitoACobrar) {
this.descricaoDebitoACobrar = descricaoDebitoACobrar;
}
public String getDescricaoGuiaPagamento() {
return descricaoGuiaPagamento;
}
public void setDescricaoGuiaPagamento(String descricaoGuiaPagamento) {
this.descricaoGuiaPagamento = descricaoGuiaPagamento;
}
public String getDescricaoImovel() {
return descricaoImovel;
}
public void setDescricaoImovel(String descricaoImovel) {
this.descricaoImovel = descricaoImovel;
}
public String getDescricaoLocalidade() {
return descricaoLocalidade;
}
public void setDescricaoLocalidade(String descricaoLocalidade) {
this.descricaoLocalidade = descricaoLocalidade;
}
public String getDescricaoTipoDebito() {
return descricaoTipoDebito;
}
public void setDescricaoTipoDebito(String descricaoTipoDebito) {
this.descricaoTipoDebito = descricaoTipoDebito;
}
public String getDocumentoTipo() {
return documentoTipo;
}
public void setDocumentoTipo(String documentoTipo) {
this.documentoTipo = documentoTipo;
}
public String getIdDebitoACobrar() {
return idDebitoACobrar;
}
public void setIdDebitoACobrar(String idDebitoACobrar) {
this.idDebitoACobrar = idDebitoACobrar;
}
public String getIdGuiaPagamento() {
return idGuiaPagamento;
}
public void setIdGuiaPagamento(String idGuiaPagamento) {
this.idGuiaPagamento = idGuiaPagamento;
}
public String getIdImovel() {
return idImovel;
}
public void setIdImovel(String idImovel) {
this.idImovel = idImovel;
}
public String getIdLocalidade() {
return idLocalidade;
}
public void setIdLocalidade(String idLocalidade) {
this.idLocalidade = idLocalidade;
}
public String getIdOrdemServico() {
return idOrdemServico;
}
public void setIdOrdemServico(String idOrdemServico) {
this.idOrdemServico = idOrdemServico;
}
public String getIdRegistroAtendimento() {
return idRegistroAtendimento;
}
public void setIdRegistroAtendimento(String idRegistroAtendimento) {
this.idRegistroAtendimento = idRegistroAtendimento;
}
public String getIdTipoDebito() {
return idTipoDebito;
}
public void setIdTipoDebito(String idTipoDebito) {
this.idTipoDebito = idTipoDebito;
}
public String getNomeCliente() {
return nomeCliente;
}
public void setNomeCliente(String nomeCliente) {
this.nomeCliente = nomeCliente;
}
public String getNomeOrdemServico() {
return nomeOrdemServico;
}
public void setNomeOrdemServico(String nomeOrdemServico) {
this.nomeOrdemServico = nomeOrdemServico;
}
public String getNomeRegistroAtendimento() {
return nomeRegistroAtendimento;
}
public void setNomeRegistroAtendimento(String nomeRegistroAtendimento) {
this.nomeRegistroAtendimento = nomeRegistroAtendimento;
}
public String getReferenciaConta() {
return referenciaConta;
}
public void setReferenciaConta(String referenciaConta) {
this.referenciaConta = referenciaConta;
}
public String getValorDebitoACobrar() {
return valorDebitoACobrar;
}
public void setValorDebitoACobrar(String valorDebitoACobrar) {
this.valorDebitoACobrar = valorDebitoACobrar;
}
public String getValorDevolucao() {
return valorDevolucao;
}
public void setValorDevolucao(String valorDevolucao) {
this.valorDevolucao = valorDevolucao;
}
public String getValorGuiaPagamento() {
return valorGuiaPagamento;
}
public void setValorGuiaPagamento(String valorGuiaPagamento) {
this.valorGuiaPagamento = valorGuiaPagamento;
}
public String getDocumentoTipoHidden() {
return documentoTipoHidden;
}
public void setDocumentoTipoHidden(String documentoTipoHidden) {
this.documentoTipoHidden = documentoTipoHidden;
}
public String getIdLocalidadeHidden() {
return idLocalidadeHidden;
}
public void setIdLocalidadeHidden(String idLocalidadeHidden) {
this.idLocalidadeHidden = idLocalidadeHidden;
}
public String getIdTipoDebitoHidden() {
return idTipoDebitoHidden;
}
public void setIdTipoDebitoHidden(String idTipoDebitoHidden) {
this.idTipoDebitoHidden = idTipoDebitoHidden;
}
public String getIdFuncionarioAnalista() {
return idFuncionarioAnalista;
}
public void setIdFuncionarioAnalista(String idFuncionarioAnalista) {
this.idFuncionarioAnalista = idFuncionarioAnalista;
}
public String getNomeFuncionarioAnalista() {
return nomeFuncionarioAnalista;
}
public void setNomeFuncionarioAnalista(String nomeFuncionarioAnalista) {
this.nomeFuncionarioAnalista = nomeFuncionarioAnalista;
}
public String getIdFuncionarioAutorizador() {
return idFuncionarioAutorizador;
}
public void setIdFuncionarioAutorizador(String idFuncionarioAutorizador) {
this.idFuncionarioAutorizador = idFuncionarioAutorizador;
}
public String getNomeFuncionarioAutorizador() {
return nomeFuncionarioAutorizador;
}
public void setNomeFuncionarioAutorizador(String nomeFuncionarioAutorizador) {
this.nomeFuncionarioAutorizador = nomeFuncionarioAutorizador;
}
}
|
[
"piagodinho@gmail.com"
] |
piagodinho@gmail.com
|
295604ec4b67bac852ee91cafda9101f069a26ad
|
635152c672f438e84ea82e1d6672157c647ef120
|
/java/squeek/veganoption/content/modules/Resin.java
|
38e5072467b161fb8ff8b3efa7a4436ff02ae849
|
[
"Unlicense"
] |
permissive
|
Sunconure11/VeganOption
|
817d51ad247f3933e30323fc227428a03706fff2
|
b4698e9edab1ce6924c083fca7c6e71dcbc81f55
|
refs/heads/master
| 2021-01-15T09:25:12.249028
| 2016-05-04T17:27:55
| 2016-05-04T17:27:55
| 58,834,983
| 0
| 0
| null | 2016-05-14T23:31:58
| 2016-05-14T23:31:58
| null |
UTF-8
|
Java
| false
| false
| 2,352
|
java
|
package squeek.veganoption.content.modules;
import net.minecraft.block.BlockLog;
import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraftforge.oredict.OreDictionary;
import squeek.veganoption.ModInfo;
import squeek.veganoption.VeganOption;
import squeek.veganoption.content.ContentHelper;
import squeek.veganoption.content.IContentModule;
import squeek.veganoption.content.Modifiers;
import squeek.veganoption.content.modifiers.DropsModifier.BlockSpecifier;
import squeek.veganoption.content.modifiers.DropsModifier.DropSpecifier;
import cpw.mods.fml.common.registry.GameRegistry;
public class Resin implements IContentModule
{
public static Item resin;
public static Item rosin;
@Override
public void create()
{
resin = new Item()
.setUnlocalizedName(ModInfo.MODID + ".resin")
.setCreativeTab(VeganOption.creativeTab)
.setTextureName(ModInfo.MODID_LOWER + ":resin");
GameRegistry.registerItem(resin, "resin");
rosin = new Item()
.setUnlocalizedName(ModInfo.MODID + ".rosin")
.setCreativeTab(VeganOption.creativeTab)
.setTextureName(ModInfo.MODID_LOWER + ":rosin");
GameRegistry.registerItem(rosin, "rosin");
}
@Override
public void oredict()
{
OreDictionary.registerOre(ContentHelper.slimeballOreDict, new ItemStack(Items.slime_ball));
OreDictionary.registerOre(ContentHelper.slimeballOreDict, new ItemStack(resin));
OreDictionary.registerOre(ContentHelper.resinOreDict, new ItemStack(resin));
OreDictionary.registerOre(ContentHelper.resinMaterialOreDict, new ItemStack(resin));
OreDictionary.registerOre(ContentHelper.rosinOreDict, new ItemStack(rosin));
OreDictionary.registerOre(ContentHelper.rosinMaterialOreDict, new ItemStack(rosin));
}
@Override
public void recipes()
{
Modifiers.recipes.convertInput(new ItemStack(Items.slime_ball), ContentHelper.slimeballOreDict);
BlockSpecifier spruceLogSpecifier = new BlockSpecifier(Blocks.log, 1)
{
@Override
public boolean metaMatches(int meta)
{
return this.meta == BlockLog.func_150165_c(meta);
}
};
Modifiers.drops.addDropsToBlock(spruceLogSpecifier, new DropSpecifier(new ItemStack(resin), 0.1f));
GameRegistry.addSmelting(resin, new ItemStack(rosin), 0.2f);
}
@Override
public void finish()
{
}
}
|
[
"squeek502@hotmail.com"
] |
squeek502@hotmail.com
|
d74d11dcd2a84a6325f3a9f850e0b4f65e961aaf
|
f72c5c691cb38114393ac5d06bc9d5e8194bdeb6
|
/SSM-WebSocket/src/main/java/com/gs/common/HttpSessionConfigurator.java
|
9469ef32b3662d90c14e618374ef32f3586d4362
|
[] |
no_license
|
ZedZhouZiBin/Javaweb
|
a3cb6a47c99b2f5fd6766b5579ad4f2e5c55cae8
|
0169feedc23522e27e7c4448a87846515b59c369
|
refs/heads/master
| 2021-09-09T13:03:36.237337
| 2018-03-16T11:49:54
| 2018-03-16T11:49:54
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 630
|
java
|
package com.gs.common;
import javax.servlet.http.HttpSession;
import javax.websocket.HandshakeResponse;
import javax.websocket.server.HandshakeRequest;
import javax.websocket.server.ServerEndpointConfig;
/**
* Created by Administrator on 2017/9/21.
*/
public class HttpSessionConfigurator extends ServerEndpointConfig.Configurator {
@Override
public void modifyHandshake(ServerEndpointConfig config, HandshakeRequest request, HandshakeResponse response){
HttpSession httpSession = (HttpSession)request.getHttpSession();
config.getUserProperties().put(HttpSession.class.getName(),httpSession);
}
}
|
[
"1729340612@qq.com"
] |
1729340612@qq.com
|
9a4c4878108c96d2d3593f2d76c6c602248c22dd
|
db921bdb69d8f48878843bcea8dff481f87af223
|
/app/src/main/java/com/campray/lesswalletandroid/util/Util.java
|
d0e868056007b376945540ce4391a47227c6edad
|
[] |
no_license
|
CampRay/LessWalletAndroid
|
431e0d46df4e0c7d5f677b486a96600cc3682c77
|
44fd40aa2fe08878d6ec47726b5ff849fa8a3f68
|
refs/heads/master
| 2021-07-06T06:23:10.519959
| 2020-07-19T05:57:05
| 2020-07-19T05:57:05
| 133,894,586
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 7,773
|
java
|
package com.campray.lesswalletandroid.util;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager;
import android.preference.PreferenceManager;
import android.util.DisplayMetrics;
import android.util.Log;
import android.view.WindowManager;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
* @author Phills
* @project Util
* @date 2016-03-01-14:55
*/
public class Util {
public static boolean checkSdCard() {
if (android.os.Environment.getExternalStorageState().equals(
android.os.Environment.MEDIA_MOUNTED))
return true;
else
return false;
}
/**
* 发送文字通知
*
* @param context
* @param Msg
* @param Title
* @param content
* @param i
*/
public static void sendText(Context context, String Msg, String Title,
String content, Intent i) {
// NotificationManager mn = (NotificationManager) context
// .getSystemService(Context.NOTIFICATION_SERVICE);
// Notification notification = new Notification(R.drawable.ic_launcher,
// Msg, System.currentTimeMillis());
// notification.flags = Notification.FLAG_AUTO_CANCEL;
// PendingIntent contentIntent = PendingIntent.getActivity(context, 0, i,
// PendingIntent.FLAG_UPDATE_CURRENT);
// notification.setLatestEventInfo(context, Title, content, contentIntent);
// mn.notify(0, notification);
// PendingIntent contentIntent = PendingIntent.getActivity(context, 0, i,
// PendingIntent.FLAG_UPDATE_CURRENT);
// Notification notification = new Notification.Builder(context)
// .setAutoCancel(true)
// .setContentTitle(Title)
// .setContentText(content)
// .setContentIntent(contentIntent)
// .setSmallIcon(R.mipmap.ic_launcher)
// .setWhen(System.currentTimeMillis())
// .build();
}
/**
* 移除SharedPreference
*
* @param context
* @param key
*/
public static final void RemoveValue(Context context, String key) {
SharedPreferences.Editor editor = getSharedPreference(context).edit();
editor.remove(key);
boolean result = editor.commit();
if (!result) {
Log.e("Remove shared data", "save " + key + " failed");
}
}
private static final SharedPreferences getSharedPreference(Context context) {
return PreferenceManager.getDefaultSharedPreferences(context);
}
/**
* 获取SharedPreference 值
*
* @param context
* @param key
* @return
*/
public static final String getValue(Context context, String key) {
return getSharedPreference(context).getString(key, "");
}
public static final Boolean getBooleanValue(Context context, String key) {
return getSharedPreference(context).getBoolean(key, false);
}
public static final void putBooleanValue(Context context, String key,
boolean bl) {
SharedPreferences.Editor edit = getSharedPreference(context).edit();
edit.putBoolean(key, bl);
edit.commit();
}
public static final int getIntValue(Context context, String key) {
return getSharedPreference(context).getInt(key, 0);
}
public static final long getLongValue(Context context, String key,
long default_data) {
return getSharedPreference(context).getLong(key, default_data);
}
public static final boolean putLongValue(Context context, String key,
Long value) {
SharedPreferences.Editor editor = getSharedPreference(context).edit();
editor.putLong(key, value);
return editor.commit();
}
public static final Boolean hasValue(Context context, String key) {
return getSharedPreference(context).contains(key);
}
/**
* 设置SharedPreference 值
*
* @param context
* @param key
* @param value
*/
public static final boolean putValue(Context context, String key,
String value) {
value = value == null ? "" : value;
SharedPreferences.Editor editor = getSharedPreference(context).edit();
editor.putString(key, value);
boolean result = editor.commit();
if (!result) {
return false;
}
return true;
}
/**
* 设置SharedPreference 值
*
* @param context
* @param key
* @param value
*/
public static final boolean putIntValue(Context context, String key,
int value) {
SharedPreferences.Editor editor = getSharedPreference(context).edit();
editor.putInt(key, value);
boolean result = editor.commit();
if (!result) {
return false;
}
return true;
}
public static Date stringToDate(String str) {
DateFormat format = new SimpleDateFormat("yyyy-MM-dd hh:mm");
Date date = null;
try {
// Fri Feb 24 00:00:00 CST 2012
date = format.parse(str);
} catch (ParseException e) {
e.printStackTrace();
}
return date;
}
/**
* 验证邮箱
*
* @param email
* @return
*/
public static boolean isEmail(String email) {
String str = "^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\\]?)$";
Pattern p = Pattern.compile(str);
Matcher m = p.matcher(email);
return m.matches();
}
/**
* 验证手机号
*
* @param mobiles
* @return
*/
public static boolean isMobileNO(String mobiles) {
Pattern p = Pattern
.compile("^((13[0-9])|(15[^4,\\D])|(17[^4,\\D])|(18[0-9]))\\d{8}$");
Matcher m = p.matcher(mobiles);
return m.matches();
}
/**
* 验证是否是数字
*
* @param str
* @return
*/
public static boolean isNumber(String str) {
Pattern pattern = Pattern.compile("[0-9]*");
java.util.regex.Matcher match = pattern.matcher(str);
if (match.matches() == false) {
return false;
} else {
return true;
}
}
/**
* 获取版本号
*
* @return 当前应用的版本号
*/
public static String getVersion(Context context) {
try {
PackageManager manager = context.getPackageManager();
PackageInfo info = manager.getPackageInfo(context.getPackageName(),
0);
String version = info.versionName;
return version;
} catch (Exception e) {
e.printStackTrace();
return "";
}
}
private static float sDensity = 0;
/**
* DP转换为像素
*
* @param context
* @param nDip
* @return
*/
public static int dipToPixel(Context context, int nDip) {
if (sDensity == 0) {
final WindowManager wm = (WindowManager) context
.getSystemService(Context.WINDOW_SERVICE);
DisplayMetrics dm = new DisplayMetrics();
wm.getDefaultDisplay().getMetrics(dm);
sDensity = dm.density;
}
return (int) (sDensity * nDip);
}
}
|
[
"phills.li@campray.com"
] |
phills.li@campray.com
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.