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
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
372a7d538e9f4be71387e120b4acdd97a6c0ad3e
|
1465bbefeaf484c893d72b95b2996a504ce30577
|
/zul/src/org/zkoss/zul/ListModelExt.java
|
4edd3e4d8745ac1f317adcc7c129b1fe0502c6c7
|
[] |
no_license
|
dije/zk
|
a2c74889d051f988e23cb056096d07f8b41133e9
|
17b8d24a970d63f65f1f3a9ffe4be999b5000304
|
refs/heads/master
| 2021-01-15T19:40:42.842829
| 2011-10-21T03:23:53
| 2011-10-21T03:23:53
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 670
|
java
|
/* ListModelExt.java
Purpose:
Description:
History:
Fri Mar 30 16:40:50 2007, Created by tomyeh
Copyright (C) 2007 Potix Corporation. All Rights Reserved.
{{IS_RIGHT
This program is distributed under LGPL Version 3.0 in the hope that
it will be useful, but WITHOUT ANY WARRANTY.
}}IS_RIGHT
*/
package org.zkoss.zul;
import java.util.Comparator;
import org.zkoss.zul.ext.Sortable;
/**
* @deprecated As of release 6.0.0, replaced with {@link Sortable}.
* An extra interface that can be implemented with {@link ListModel}
* to control the sorting of the data model.
*
* @author tomyeh
*/
public interface ListModelExt<T> extends Sortable<T> {
}
|
[
"tomyeh@zkoss.org"
] |
tomyeh@zkoss.org
|
ebf6eb03992bfca3b33578a30c3ee967263bc889
|
5a474257353b9bbf88c30688fab17a618b154c22
|
/snHose-Server/src/main/java/net/minecraft/server/ChatModifier.java
|
3323515f79e3e63e55517a025a1e4cf67b09af9c
|
[] |
no_license
|
RealKezuk/snHose
|
7e5424cd3edbf99bb6a586b9592943b11cd9d549
|
8c89453218621426f394fae44625f97b2a57840c
|
refs/heads/master
| 2020-07-22T14:24:17.936438
| 2019-09-09T03:39:21
| 2019-09-09T03:39:21
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,853
|
java
|
package net.minecraft.server.v1_7_R4;
public class ChatModifier
{
private ChatModifier a;
private EnumChatFormat b;
private Boolean c;
private Boolean d;
private Boolean e;
private Boolean f;
private Boolean g;
private ChatClickable h;
private ChatHoverable i;
private static final ChatModifier j;
public EnumChatFormat a() {
return (this.b == null) ? this.n().a() : this.b;
}
public boolean b() {
return (this.c == null) ? this.n().b() : this.c;
}
public boolean c() {
return (this.d == null) ? this.n().c() : this.d;
}
public boolean d() {
return (this.f == null) ? this.n().d() : this.f;
}
public boolean e() {
return (this.e == null) ? this.n().e() : this.e;
}
public boolean f() {
return (this.g == null) ? this.n().f() : this.g;
}
public boolean g() {
return this.c == null && this.d == null && this.f == null && this.e == null && this.g == null && this.b == null && this.h == null && this.i == null;
}
public ChatClickable h() {
return (this.h == null) ? this.n().h() : this.h;
}
public ChatHoverable i() {
return (this.i == null) ? this.n().i() : this.i;
}
public ChatModifier setColor(final EnumChatFormat b) {
this.b = b;
return this;
}
public ChatModifier setBold(final Boolean c) {
this.c = c;
return this;
}
public ChatModifier setItalic(final Boolean d) {
this.d = d;
return this;
}
public ChatModifier setStrikethrough(final Boolean f) {
this.f = f;
return this;
}
public ChatModifier setUnderline(final Boolean e) {
this.e = e;
return this;
}
public ChatModifier setRandom(final Boolean g) {
this.g = g;
return this;
}
public ChatModifier setChatClickable(final ChatClickable h) {
this.h = h;
return this;
}
public ChatModifier a(final ChatHoverable i) {
this.i = i;
return this;
}
public ChatModifier a(final ChatModifier a) {
this.a = a;
return this;
}
private ChatModifier n() {
return (this.a == null) ? ChatModifier.j : this.a;
}
@Override
public String toString() {
return "Style{hasParent=" + (this.a != null) + ", color=" + this.b + ", bold=" + this.c + ", italic=" + this.d + ", underlined=" + this.e + ", obfuscated=" + this.g + ", clickEvent=" + this.h() + ", hoverEvent=" + this.i() + '}';
}
@Override
public boolean equals(final Object o) {
if (this == o) {
return true;
}
if (o instanceof ChatModifier) {
final ChatModifier chatModifier = (ChatModifier)o;
if (this.b() == chatModifier.b() && this.a() == chatModifier.a() && this.c() == chatModifier.c() && this.f() == chatModifier.f() && this.d() == chatModifier.d() && this.e() == chatModifier.e()) {
if (this.h() != null) {
if (!this.h().equals(chatModifier.h())) {
return false;
}
}
else if (chatModifier.h() != null) {
return false;
}
if ((this.i() == null) ? (chatModifier.i() == null) : this.i().equals(chatModifier.i())) {
return true;
}
}
return false;
}
return false;
}
@Override
public int hashCode() {
return 31 * (31 * (31 * (31 * (31 * (31 * (31 * this.b.hashCode() + this.c.hashCode()) + this.d.hashCode()) + this.e.hashCode()) + this.f.hashCode()) + this.g.hashCode()) + this.h.hashCode()) + this.i.hashCode();
}
public ChatModifier clone() {
final ChatModifier chatModifier = new ChatModifier();
chatModifier.c = this.c;
chatModifier.d = this.d;
chatModifier.f = this.f;
chatModifier.e = this.e;
chatModifier.g = this.g;
chatModifier.b = this.b;
chatModifier.h = this.h;
chatModifier.i = this.i;
chatModifier.a = this.a;
return chatModifier;
}
public ChatModifier m() {
final ChatModifier chatModifier = new ChatModifier();
chatModifier.setBold(this.b());
chatModifier.setItalic(this.c());
chatModifier.setStrikethrough(this.d());
chatModifier.setUnderline(this.e());
chatModifier.setRandom(this.f());
chatModifier.setColor(this.a());
chatModifier.setChatClickable(this.h());
chatModifier.a(this.i());
return chatModifier;
}
static {
j = new ChatStyleRoot();
}
}
|
[
"sathonaypro@gmail.com"
] |
sathonaypro@gmail.com
|
1fe148a78b2ff70417022e0516240955aebc8865
|
3ea35a9d2a32a11f2c6e0fa21860f73c042ca1b3
|
/II курс/Trim2/Практикум ООП и ДБ/h2/src/main/org/h2/engine/SessionInterface.java
|
e293e0f1aa1329bdfaa26f3c3c1b92b87378994c
|
[] |
no_license
|
angelzbg/Informatika
|
35be4926c16fb1eb2fd8e9459318c5ea9f5b1fd8
|
6c9e16087a30253e1a6d5cd9e9346a7cdd4b3e17
|
refs/heads/master
| 2021-02-08T14:50:46.438583
| 2020-03-01T14:18:26
| 2020-03-01T14:18:26
| 244,162,465
| 7
| 2
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,750
|
java
|
/*
* Copyright 2004-2014 H2 Group. Multiple-Licensed under the MPL 2.0,
* and the EPL 1.0 (http://h2database.com/html/license.html).
* Initial Developer: H2 Group
*/
package org.h2.engine;
import java.io.Closeable;
import java.util.ArrayList;
import org.h2.command.CommandInterface;
import org.h2.message.Trace;
import org.h2.store.DataHandler;
import org.h2.value.Value;
/**
* A local or remote session. A session represents a database connection.
*/
public interface SessionInterface extends Closeable {
/**
* Get the list of the cluster servers for this session.
*
* @return A list of "ip:port" strings for the cluster servers in this
* session.
*/
ArrayList<String> getClusterServers();
/**
* Parse a command and prepare it for execution.
*
* @param sql the SQL statement
* @param fetchSize the number of rows to fetch in one step
* @return the prepared command
*/
CommandInterface prepareCommand(String sql, int fetchSize);
/**
* Roll back pending transactions and close the session.
*/
@Override
void close();
/**
* Get the trace object
*
* @return the trace object
*/
Trace getTrace();
/**
* Check if close was called.
*
* @return if the session has been closed
*/
boolean isClosed();
/**
* Get the number of disk operations before power failure is simulated.
* This is used for testing. If not set, 0 is returned
*
* @return the number of operations, or 0
*/
int getPowerOffCount();
/**
* Set the number of disk operations before power failure is simulated.
* To disable the countdown, use 0.
*
* @param i the number of operations
*/
void setPowerOffCount(int i);
/**
* Get the data handler object.
*
* @return the data handler
*/
DataHandler getDataHandler();
/**
* Check whether this session has a pending transaction.
*
* @return true if it has
*/
boolean hasPendingTransaction();
/**
* Cancel the current or next command (called when closing a connection).
*/
void cancel();
/**
* Check if the database changed and therefore reconnecting is required.
*
* @param write if the next operation may be writing
* @return true if reconnecting is required
*/
boolean isReconnectNeeded(boolean write);
/**
* Close the connection and open a new connection.
*
* @param write if the next operation may be writing
* @return the new connection
*/
SessionInterface reconnect(boolean write);
/**
* Called after writing has ended. It needs to be called after
* isReconnectNeeded(true) returned false.
*/
void afterWriting();
/**
* Check if this session is in auto-commit mode.
*
* @return true if the session is in auto-commit mode
*/
boolean getAutoCommit();
/**
* Set the auto-commit mode. This call doesn't commit the current
* transaction.
*
* @param autoCommit the new value
*/
void setAutoCommit(boolean autoCommit);
/**
* Add a temporary LOB, which is closed when the session commits.
*
* @param v the value
*/
void addTemporaryLob(Value v);
/**
* Check if this session is remote or embedded.
*
* @return true if this session is remote
*/
boolean isRemote();
/**
* Set current schema.
*
* @param schema the schema name
*/
void setCurrentSchemaName(String schema);
/**
* Get current schema.
*
* @return the current schema name
*/
String getCurrentSchemaName();
}
|
[
"badblo0dbg@gmail.com"
] |
badblo0dbg@gmail.com
|
2bc74b4531de73f5407eb9a761e87e2be9438810
|
ab2d5ad8321e748146420903bf0effabc9b8ad64
|
/src/main/java/theflogat/technomancy/common/blocks/base/BlockCoilTransmitter.java
|
2407624184920e4ab3eb2983e258cd364ff527d6
|
[] |
no_license
|
abused/Technomancy-2
|
3bf9d367bc7b06a17b20a7c165089747697eb507
|
223160a924e6f2c3c2170f2b9fa8b291a07cd31b
|
refs/heads/master
| 2021-04-27T00:07:24.778160
| 2018-07-16T03:45:35
| 2018-07-16T03:45:35
| 123,752,686
| 1
| 2
| null | 2020-08-27T10:43:10
| 2018-03-04T03:19:10
|
Java
|
UTF-8
|
Java
| false
| false
| 3,269
|
java
|
package theflogat.technomancy.common.blocks.base;
import java.util.ArrayList;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import theflogat.technomancy.common.tiles.base.TileCoilTransmitter;
import theflogat.technomancy.lib.Names;
import theflogat.technomancy.lib.Ref;
import javax.annotation.Nullable;
public abstract class BlockCoilTransmitter extends BlockContainerAdvanced {
public AxisAlignedBB bb = new AxisAlignedBB(0.1875F, 0.0F, 0.1875F, 0.8125F, 1.0F, 0.8125F);
public BlockCoilTransmitter() {
}
@Override
public AxisAlignedBB getBoundingBox(IBlockState state, IBlockAccess world, BlockPos pos) {
TileCoilTransmitter tile = getTE(world, pos);
AxisAlignedBB bounding = bb;
if(tile != null) {
switch(tile.facing) {
case 0:
case 1:
bounding = new AxisAlignedBB(0.1875F, 0.0F, 0.1875F, 0.8125F, 1.0F, 0.8125F);
break;
case 2:
case 3:
bounding = new AxisAlignedBB(0.1875F, 0.1875F, 0.0F, 0.8125F, 0.8125F, 1.0F);
break;
case 4:
case 5:
bounding = new AxisAlignedBB(0.0F, 0.1875F, 0.1875F, 1.0F, 0.8125F, 0.8125F);
break;
default:
bounding = bb;
}
}
return bounding;
}
@Nullable
@Override
public AxisAlignedBB getCollisionBoundingBox(IBlockState blockState, IBlockAccess worldIn, BlockPos pos) {
return bb;
}
@Override
public int getStrongPower(IBlockState blockState, IBlockAccess blockAccess, BlockPos pos, EnumFacing side) {
TileCoilTransmitter tile = getTE(blockAccess, pos);
if(tile!=null) {
return tile.redstoneState ? 15 : 0;
}
return 0;
}
@Override
public int getWeakPower(IBlockState blockState, IBlockAccess blockAccess, BlockPos pos, EnumFacing side) {
TileCoilTransmitter tile = getTE(blockAccess, pos);
if(tile!=null) {
return tile.redstoneState ? 15 : 0;
}
return 0;
}
@Override
public boolean canConnectRedstone(IBlockState state, IBlockAccess world, BlockPos pos, @Nullable EnumFacing side) {
TileCoilTransmitter tile = getTE(world, pos);
if(tile!=null) {
return tile.getBoost();
}
return false;
}
@Override
public void onBlockPlacedBy(World w, BlockPos pos, IBlockState state, EntityLivingBase placer, ItemStack stack) {
super.onBlockPlacedBy(w, pos, state, placer, stack);
TileCoilTransmitter tile = getTE(w, pos);
if(tile!=null) {
tile.clear();
w.setBlockState(pos, state);
}
}
@Override
public boolean isOpaqueCube(IBlockState state) {
return false;
}
@Override
public boolean isNormalCube(IBlockState state, IBlockAccess world, BlockPos pos) {
return false;
}
private static TileCoilTransmitter getTE(IBlockAccess world, BlockPos pos) {
TileEntity tile = world.getTileEntity(pos);
return tile instanceof TileCoilTransmitter ? (TileCoilTransmitter)tile : null;
}
@Override
public void getNBTInfo(NBTTagCompound comp, ArrayList<String> l, int meta) {
super.getNBTInfo(comp, l, meta);
}
}
|
[
"techperson71@gmail.com"
] |
techperson71@gmail.com
|
7d9574f4aeb32c8c74b1106136f9d83bf7c9c5b6
|
0fa9b0c5f829210c2cccd99827abdd21929ac3b1
|
/src/com/lm/bos/service/INoticebillService.java
|
fba595ff4bbd0f6eb8495cbe68fddd481a529c82
|
[] |
no_license
|
louiema1n/bos
|
86e0d49fd9ef4ee07093574bfb86835c253d734b
|
77b59ecc97324107801d491002cdfa8ed4fa57c3
|
refs/heads/master
| 2021-01-12T08:21:47.639817
| 2016-12-25T03:09:28
| 2016-12-25T03:09:28
| 76,553,569
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 143
|
java
|
package com.lm.bos.service;
import com.lm.bos.domain.QpNoticebill;
public interface INoticebillService {
void save(QpNoticebill model);
}
|
[
"louielcxy@live.cn"
] |
louielcxy@live.cn
|
91236b8cca9f5f40ea1c721b9e4407ddd1dadf1e
|
e9a1c638bdbd862c0998addd50e2dce5561a3244
|
/functionalj-core/src/main/java/functionalj/list/FuncListWithMapTuple.java
|
33b292adf8d31a5399b65085dcc4b5e01446052b
|
[
"MIT"
] |
permissive
|
tanhuazh/FunctionalJ
|
c1f024ad2e9e7357caaadfbbc198f8bd074eee85
|
d4778044065d4a68eb1f10d227f4481f881ca48e
|
refs/heads/master
| 2023-04-28T09:12:48.707534
| 2019-09-25T04:34:29
| 2019-09-25T04:34:29
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,440
|
java
|
// ============================================================================
// Copyright (c) 2017-2019 Nawapunth Manusitthipol (NawaMan - http://nawaman.net).
// ----------------------------------------------------------------------------
// MIT License
//
// 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.
// ============================================================================
package functionalj.list;
import java.util.function.Function;
import java.util.stream.Stream;
import functionalj.stream.Streamable;
import functionalj.stream.StreamableWithMapTuple;
import functionalj.tuple.Tuple2;
import functionalj.tuple.Tuple3;
import functionalj.tuple.Tuple4;
import functionalj.tuple.Tuple5;
import functionalj.tuple.Tuple6;
public interface FuncListWithMapTuple<DATA>
extends StreamableWithMapTuple<DATA> {
public <TARGET> FuncList<TARGET> deriveFrom(Function<Streamable<DATA>, Stream<TARGET>> action);
//== mapTuple ==
public default <T1, T2>
FuncList<Tuple2<T1, T2>> mapTuple(
Function<? super DATA, T1> mapper1,
Function<? super DATA, T2> mapper2) {
return deriveFrom(streamable -> {
return streamable
.stream()
.mapTuple(mapper1, mapper2);
});
}
public default <T1, T2, T3>
FuncList<Tuple3<T1, T2, T3>> mapTuple(
Function<? super DATA, T1> mapper1,
Function<? super DATA, T2> mapper2,
Function<? super DATA, T3> mapper3) {
return deriveFrom(streamable -> {
return streamable
.stream()
.mapTuple(mapper1, mapper2, mapper3);
});
}
public default <T1, T2, T3, T4>
FuncList<Tuple4<T1, T2, T3, T4>> mapTuple(
Function<? super DATA, T1> mapper1,
Function<? super DATA, T2> mapper2,
Function<? super DATA, T3> mapper3,
Function<? super DATA, T4> mapper4) {
return deriveFrom(streamable -> {
return streamable
.stream()
.mapTuple(mapper1, mapper2, mapper3, mapper4);
});
}
public default <T1, T2, T3, T4, T5>
FuncList<Tuple5<T1, T2, T3, T4, T5>> mapTuple(
Function<? super DATA, T1> mapper1,
Function<? super DATA, T2> mapper2,
Function<? super DATA, T3> mapper3,
Function<? super DATA, T4> mapper4,
Function<? super DATA, T5> mapper5) {
return deriveFrom(streamable -> {
return streamable
.stream()
.mapTuple(mapper1, mapper2, mapper3, mapper4, mapper5);
});
}
public default <T1, T2, T3, T4, T5, T6>
FuncList<Tuple6<T1, T2, T3, T4, T5, T6>> mapTuple(
Function<? super DATA, T1> mapper1,
Function<? super DATA, T2> mapper2,
Function<? super DATA, T3> mapper3,
Function<? super DATA, T4> mapper4,
Function<? super DATA, T5> mapper5,
Function<? super DATA, T6> mapper6) {
return deriveFrom(streamable -> {
return streamable
.stream()
.mapTuple(mapper1, mapper2, mapper3, mapper4, mapper5, mapper6);
});
}
}
|
[
"nawa@nawaman.net"
] |
nawa@nawaman.net
|
7687d6bd146bfe41694eaf9bd32a4d5d47c6c0ea
|
f0ec508f4b480d8d5399a2880e4cbb0533fc2fc1
|
/com.ouchgzee.headTeacher.biz/src/main/java/com/ouchgzee/headTeacher/constants/shiro/filter/LoginFormAuthenticationFilter.java
|
5c994b90c015cf7beb9cf63323894e5af7c62044
|
[] |
no_license
|
lizm335/MyLizm
|
a327bd4d08a33c79e9b6ef97144d63dae7114a52
|
1bcca82395b54d431fb26817e61a294f9d7dd867
|
refs/heads/master
| 2020-03-11T17:25:25.687426
| 2018-04-19T03:10:28
| 2018-04-19T03:10:28
| 130,146,458
| 3
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,677
|
java
|
/**
* Copyright(c) 2013 版权所有:广州远程教育中心 www.969300.com
*/
package com.ouchgzee.headTeacher.constants.shiro.filter;
import org.apache.commons.lang3.StringUtils;
import org.apache.log4j.Logger;
import org.apache.shiro.authc.AuthenticationToken;
import org.apache.shiro.subject.Subject;
import org.apache.shiro.web.filter.authc.FormAuthenticationFilter;
import org.apache.shiro.web.util.WebUtils;
import com.gzedu.xlims.common.Md5Util;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
/**
* 功能说明:
* @author 朱恒勇 zhuhengyong@eenet.com
* @Date 2016年5月17日
* @version 2.5
*
*/
public class LoginFormAuthenticationFilter extends FormAuthenticationFilter{
protected final Logger logger = Logger.getLogger(LoginFormAuthenticationFilter.class);
@Override
protected boolean onLoginSuccess(AuthenticationToken token, Subject subject, ServletRequest request,
ServletResponse response) throws Exception {
boolean contextRelative = true;
String successUrl = this.getSuccessUrl();
if ("".equals(successUrl)) {
successUrl = DEFAULT_SUCCESS_URL;
}
WebUtils.issueRedirect(request, response, successUrl, null, contextRelative);
return false;
}
@Override
protected AuthenticationToken createToken(ServletRequest request, ServletResponse response) {
String username = getUsername(request);
String password = getPassword(request);
if (StringUtils.isNotEmpty(password)) {
try {
password = Md5Util.encrypt(getPassword(request));
} catch (Exception e) {
}
}
return createToken(username, password, request, response);
}
}
|
[
"lizengming@eenet.com"
] |
lizengming@eenet.com
|
b8a329095b2e867775f3d5f072c732a9b27a7838
|
b34654bd96750be62556ed368ef4db1043521ff2
|
/component_-_check_profile_completeness_servlet_filter/tags/version-1.0.0.1/src/java/tests/com/topcoder/reg/profilecompleteness/filter/accuracytests/retrievers/StudioUserIdRetrieverAccuracyTest.java
|
3eeceb8a054c7f32860e9f45d30b6b11a575d8cd
|
[] |
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
| 5,931
|
java
|
/*
* Copyright (C) 2011 TopCoder Inc., All Rights Reserved.
*/
package com.topcoder.reg.profilecompleteness.filter.accuracytests.retrievers;
import javax.servlet.http.HttpServletRequest;
import junit.framework.JUnit4TestAdapter;
import org.junit.After;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
import org.springframework.mock.web.MockHttpServletRequest;
import com.topcoder.reg.profilecompleteness.filter.impl.retrievers.StudioUserIdRetriever;
import com.topcoder.shared.security.Persistor;
import com.topcoder.shared.security.SimpleUser;
import com.topcoder.shared.security.User;
import com.topcoder.util.log.basic.BasicLogFactory;
import com.topcoder.web.common.SimpleRequest;
import com.topcoder.web.common.security.BasicAuthentication;
import com.topcoder.web.common.security.SessionPersistor;
/**
* <p>
* Accuracy test for {@link StudioUserIdRetriever}.
* </p>
*
* @author gets0ul
* @version 1.0
*/
public class StudioUserIdRetrieverAccuracyTest {
/**
* The StudioUserIdRetriever instance to test against.
*/
private StudioUserIdRetriever retriever;
/**
* <p>
* Creates a test suite for the tests in this test case.
* </p>
*
* @return a Test suite for this test case.
*/
public static junit.framework.Test suite() {
return new JUnit4TestAdapter(StudioUserIdRetrieverAccuracyTest.class);
}
/**
* <p>
* Sets up test environment.
* </p>
*
* @throws Exception
* to junit
*/
@Before
public void setUp() throws Exception {
retriever = new StudioUserIdRetriever();
retriever.setLog(new BasicLogFactory().createLog("test"));
}
/**
* <p>
* Tears down test environment.
* </p>
*
* @throws Exception
* to junit
*/
@After
public void tearDown() throws Exception {
retriever = null;
}
/**
* <p>
* Tests StudioUserIdRetriever constructor.
* </p>
* <p>
* Instance should be created. No exception is expected.
* </p>
*/
@Test
public void testCtor() {
Assert.assertNotNull("StudioUserIdRetriever is not instantiated", retriever);
}
/**
* <p>
* Tests {@link StudioUserIdRetriever#getUserId(javax.servlet.http.HttpServletRequest)} method when a
* BasicAuthentication instance is stored in user session key attribute and user is active/logged.
* </p>
* <p>
* Expects the correct user id is returned.
* </p>
*
* @throws Exception
* to junit
*/
@Test
public void testGetUserId1() throws Exception {
HttpServletRequest request = new MockHttpServletRequest();
// Create a Persistor so we can persist a "logged" user
Persistor persistor = new SessionPersistor(request.getSession());
User user = new SimpleUser(2, "user", "password");
persistor.setObject("user_obj", user);
BasicAuthentication auth = new BasicAuthentication(persistor, new SimpleRequest(request), null,
BasicAuthentication.MAIN_SITE);
request.getSession().setAttribute("key", auth);
retriever.setUserSessionKey("key");
Long userId = retriever.getUserId(request);
// verify it
Assert.assertNotNull("The user id should exist for logged user", userId);
Assert.assertEquals("Incorrect user id", user.getId(), userId.longValue());
}
/**
* <p>
* Tests {@link StudioUserIdRetriever#getUserId(javax.servlet.http.HttpServletRequest)} method when a
* BasicAuthentication instance is stored in user session key attribute and user is not active/logged.
* </p>
* <p>
* Expects null is returned.
* </p>
*
* @throws Exception
* to junit
*/
@Test
public void testGetUserId2() throws Exception {
HttpServletRequest request = new MockHttpServletRequest();
BasicAuthentication auth = new BasicAuthentication(new SessionPersistor(request.getSession()),
new SimpleRequest(request), null, BasicAuthentication.MAIN_SITE);
request.getSession().setAttribute("key", auth);
retriever.setUserSessionKey("key");
Long userId = retriever.getUserId(request);
// verify it
Assert.assertNull("The user id should not exist for anonymous user", userId);
}
/**
* <p>
* Tests {@link StudioUserIdRetriever#getUserId(javax.servlet.http.HttpServletRequest)} method when a
* BasicAuthentication instance is not stored in user session key attribute.
* </p>
* <p>
* Expects null is returned.
* </p>
*/
@Test
public void testGetUserId3() {
retriever.setUserSessionKey("key");
HttpServletRequest request = new MockHttpServletRequest();
request.getSession().setAttribute("key", null);
Long userId = retriever.getUserId(request);
// verify it
Assert.assertNull("The user id should not exist", userId);
}
/**
* <p>
* Tests {@link StudioUserIdRetriever#getUserId(javax.servlet.http.HttpServletRequest)} method when another
* type of instance is stored in user session key attribute.
* </p>
* <p>
* Expects null is returned.
* </p>
*/
@Test
public void testGetUserId4() {
retriever.setUserSessionKey("key");
HttpServletRequest request = new MockHttpServletRequest();
request.getSession().setAttribute("key", new Integer(1));
Long userId = retriever.getUserId(request);
// verify it
Assert.assertNull("The user id should not exist", userId);
}
}
|
[
"tingyifang@fb370eea-3af6-4597-97f7-f7400a59c12a"
] |
tingyifang@fb370eea-3af6-4597-97f7-f7400a59c12a
|
6c1dc878894f5f0dfee59ca6a68880284a2e28f4
|
04a2313e35dace9c3a6999c2e990552793513be5
|
/rest/src/main/java/com/apress/springrecipes/court/service/ReservationNotAvailableException.java
|
411d32a30112d2b29def3299acb4b31eae25a623
|
[] |
no_license
|
wikibook/spring3recipes
|
33292623707fef930e1cdbe57751dbbbcfc86f82
|
0af62691b1c1cc85f7848a0d4e12a089eb92275e
|
refs/heads/master
| 2021-01-18T14:46:12.756107
| 2013-10-25T16:06:12
| 2013-10-25T16:06:12
| 13,865,435
| 1
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 635
|
java
|
package com.apress.springrecipes.court.service;
import java.util.Date;
public class ReservationNotAvailableException extends RuntimeException {
public static final long serialVersionUID = 1L;
private String courtName;
private Date date;
private int hour;
public ReservationNotAvailableException(String courtName, Date date, int hour) {
this.courtName = courtName;
this.date = date;
this.hour = hour;
}
public String getCourtName() {
return courtName;
}
public Date getDate() {
return date;
}
public int getHour() {
return hour;
}
}
|
[
"dylee@wikibook.co.kr"
] |
dylee@wikibook.co.kr
|
b2b5d18327117a9df45c0bdf30aec1740fa1e900
|
5b8f0cbd2076b07481bd62f26f5916d09a050127
|
/src/TopologicalSortTest2.java
|
b18669f23577e7f1b86626c73c6e05ab3f330fb8
|
[] |
no_license
|
micgogi/micgogi_algo
|
b45664de40ef59962c87fc2a1ee81f86c5d7c7ba
|
7cffe8122c04059f241270bf45e033b1b91ba5df
|
refs/heads/master
| 2022-07-13T00:00:56.090834
| 2022-06-15T14:02:51
| 2022-06-15T14:02:51
| 209,986,655
| 7
| 3
| null | 2020-10-20T07:41:03
| 2019-09-21T13:06:43
|
Java
|
UTF-8
|
Java
| false
| false
| 1,547
|
java
|
import java.util.Iterator;
import java.util.LinkedList;
import java.util.Stack;
/**
* @author Micgogi
* on 4/30/2020 3:24 PM
* Rahul Gogyani
*/
public class TopologicalSortTest2 {
static class Graph{
int v;
LinkedList<Integer> adjList[];
public Graph(int v){
this.v = v;
adjList = new LinkedList[v];
for (int i = 0; i <v ; i++) {
adjList[i] = new LinkedList<>();
}
}
public void addEdge(int s, int d){
adjList[s].add(d);
}
}
public static void topologicalSort(int v, Graph g){
boolean visited[] = new boolean[v];
Stack<Integer> stack= new Stack();
for (int i = 0; i <v ; i++) {
if(!visited[i]){
dfs(i,g,stack,visited );
}
}
while (!stack.isEmpty()){
System.out.println(stack.pop());
}
}
private static void dfs(int i, Graph g, Stack<Integer> stack, boolean[] visited) {
visited[i] = true;
Iterator<Integer> iterator = g.adjList[i].iterator();
Integer a =0;
while(iterator.hasNext()){
a = iterator.next();
if(!visited[a]){
dfs(a,g,stack,visited);
}
}
stack.push(new Integer(i));
}
public static void main(String[] args) {
Graph g = new Graph(4);
g.addEdge(0,1);
g.addEdge(0,2);
g.addEdge(1,3);
g.addEdge(2,3);
topologicalSort(0,g);
}
}
|
[
"rahul.gogyani@gmail.com"
] |
rahul.gogyani@gmail.com
|
1f27916c87c11f84234ea344932588a94e942343
|
409bdfcaa53e73a69c816da3605001c6e0e7042d
|
/3.JavaMultithreading/src/com/javarush/task/task22/task2204/Solution.java
|
1c76a5c9c0671cd4d024a758dab2de7d10789d14
|
[] |
no_license
|
sebelousov/javarushtasks
|
2a4c8ebcdba94196276b61688bb73ccf2cad039e
|
2710a327278ba04b40637cd5918491ef70ced117
|
refs/heads/master
| 2023-03-25T09:41:19.840213
| 2021-03-24T13:56:49
| 2021-03-24T13:56:49
| 351,092,038
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 582
|
java
|
package com.javarush.task.task22.task2204;
/*
Форматирование строки
*/
public class Solution {
public static void main(String[] args) {
//System.out.println(String.format(getFormattedString(), 20.0 / 7.0, 10.0 / 3.0));
System.out.println(String.format(getFormattedString(), 20.0 / 7.0, 10.0 / 3.0));
//должен быть вывод
//20 / 7 = 2,86
//Exp = 3,33e+00
}
public static String getFormattedString() {
//return "20 / 7 = %n %Exp = %";
return "20 / 7 = %.2f%nExp = %.2e";
}
}
|
[
"bsn@list.ru"
] |
bsn@list.ru
|
49cfd8fe35975c927e148dda3d1ef809f2ea6382
|
d93ce8a57be61625c4259b41f860c596726bd2af
|
/src/main/java/soot/baf/OrInst.java
|
7ddd9f0d54ed62021c2dd9e825cf2c2605357650
|
[
"Apache-2.0"
] |
permissive
|
izgzhen/markii
|
81b67049ce817582736c8d630ec0e2cd12caa214
|
237a054a72f01121ce0fefac7532c1a39444e852
|
refs/heads/master
| 2023-05-06T00:24:48.026714
| 2021-04-14T17:41:27
| 2021-04-16T06:29:12
| 275,070,321
| 5
| 0
|
Apache-2.0
| 2021-04-16T06:29:13
| 2020-06-26T04:06:53
|
Java
|
UTF-8
|
Java
| false
| false
| 905
|
java
|
package soot.baf;
/*-
* #%L
* Soot - a J*va Optimization Framework
* %%
* Copyright (C) 1999 Patrick Lam, Patrick Pominville and Raja Vallee-Rai
* %%
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation, either version 2.1 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 Lesser Public License for more details.
*
* You should have received a copy of the GNU General Lesser Public
* License along with this program. If not, see
* <http://www.gnu.org/licenses/lgpl-2.1.html>.
* #L%
*/
public interface OrInst extends OpTypeArgInst {
}
|
[
"7168454+izgzhen@users.noreply.github.com"
] |
7168454+izgzhen@users.noreply.github.com
|
35e96a2ee908a1b6a2cd67da6ba8b528860dd257
|
8af1164bac943cef64e41bae312223c3c0e38114
|
/results-java/apache--zeppelin/fe8b226f02cb7f2ae0b5d2cfdce118f7105fe879/before/NoteTest.java
|
dd79dad82aa93302c2a41ccfee57ff0695ea81bc
|
[] |
no_license
|
fracz/refactor-extractor
|
3ae45c97cc63f26d5cb8b92003b12f74cc9973a9
|
dd5e82bfcc376e74a99e18c2bf54c95676914272
|
refs/heads/master
| 2021-01-19T06:50:08.211003
| 2018-11-30T13:00:57
| 2018-11-30T13:00:57
| 87,353,478
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 7,417
|
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.zeppelin.notebook;
import org.apache.zeppelin.interpreter.Interpreter;
import org.apache.zeppelin.interpreter.InterpreterFactory;
import org.apache.zeppelin.interpreter.InterpreterResult;
import org.apache.zeppelin.notebook.repo.NotebookRepo;
import org.apache.zeppelin.scheduler.Scheduler;
import org.apache.zeppelin.search.SearchService;
import org.apache.zeppelin.user.AuthenticationInfo;
import org.apache.zeppelin.user.Credentials;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
import org.mockito.Mock;
import org.mockito.runners.MockitoJUnitRunner;
import static org.junit.Assert.*;
import static org.mockito.Mockito.*;
@RunWith(MockitoJUnitRunner.class)
public class NoteTest {
@Mock
NotebookRepo repo;
@Mock
JobListenerFactory jobListenerFactory;
@Mock
SearchService index;
@Mock
Credentials credentials;
@Mock
Interpreter interpreter;
@Mock
Scheduler scheduler;
@Mock
NoteEventListener noteEventListener;
@Mock
InterpreterFactory interpreterFactory;
private AuthenticationInfo anonymous = new AuthenticationInfo("anonymous");
@Test
public void runNormalTest() {
when(interpreterFactory.getInterpreter(anyString(), anyString(), eq("spark"))).thenReturn(interpreter);
when(interpreter.getScheduler()).thenReturn(scheduler);
String pText = "%spark sc.version";
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
Paragraph p = note.addParagraph(AuthenticationInfo.ANONYMOUS);
p.setText(pText);
p.setAuthenticationInfo(anonymous);
note.run(p.getId());
ArgumentCaptor<Paragraph> pCaptor = ArgumentCaptor.forClass(Paragraph.class);
verify(scheduler, only()).submit(pCaptor.capture());
verify(interpreterFactory, times(2)).getInterpreter(anyString(), anyString(), eq("spark"));
assertEquals("Paragraph text", pText, pCaptor.getValue().getText());
}
@Test
public void addParagraphWithEmptyReplNameTest() {
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
Paragraph p = note.addParagraph(AuthenticationInfo.ANONYMOUS);
assertNull(p.getText());
}
@Test
public void addParagraphWithLastReplNameTest() {
when(interpreterFactory.getInterpreter(anyString(), anyString(), eq("spark"))).thenReturn(interpreter);
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
Paragraph p1 = note.addParagraph(AuthenticationInfo.ANONYMOUS);
p1.setText("%spark ");
Paragraph p2 = note.addParagraph(AuthenticationInfo.ANONYMOUS);
assertEquals("%spark\n", p2.getText());
}
@Test
public void insertParagraphWithLastReplNameTest() {
when(interpreterFactory.getInterpreter(anyString(), anyString(), eq("spark"))).thenReturn(interpreter);
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
Paragraph p1 = note.addParagraph(AuthenticationInfo.ANONYMOUS);
p1.setText("%spark ");
Paragraph p2 = note.insertParagraph(note.getParagraphs().size(), AuthenticationInfo.ANONYMOUS);
assertEquals("%spark\n", p2.getText());
}
@Test
public void insertParagraphWithInvalidReplNameTest() {
when(interpreterFactory.getInterpreter(anyString(), anyString(), eq("invalid"))).thenReturn(null);
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
Paragraph p1 = note.addParagraph(AuthenticationInfo.ANONYMOUS);
p1.setText("%invalid ");
Paragraph p2 = note.insertParagraph(note.getParagraphs().size(), AuthenticationInfo.ANONYMOUS);
assertNull(p2.getText());
}
@Test
public void clearAllParagraphOutputTest() {
when(interpreterFactory.getInterpreter(anyString(), anyString(), eq("md"))).thenReturn(interpreter);
when(interpreter.getScheduler()).thenReturn(scheduler);
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
Paragraph p1 = note.addParagraph(AuthenticationInfo.ANONYMOUS);
InterpreterResult result = new InterpreterResult(InterpreterResult.Code.SUCCESS, InterpreterResult.Type.TEXT, "result");
p1.setResult(result);
Paragraph p2 = note.addParagraph(AuthenticationInfo.ANONYMOUS);
p2.setReturn(result, new Throwable());
note.clearAllParagraphOutput();
assertNull(p1.getReturn());
assertNull(p2.getReturn());
}
@Test
public void getFolderIdTest() {
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
// Ordinary case test
note.setName("this/is/a/folder/noteName");
assertEquals("this/is/a/folder", note.getFolderId());
// Normalize test
note.setName("/this/is/a/folder/noteName");
assertEquals("this/is/a/folder", note.getFolderId());
// Root folder test
note.setName("noteOnRootFolder");
assertEquals(Folder.ROOT_FOLDER_ID, note.getFolderId());
note.setName("/noteOnRootFolderStartsWithSlash");
assertEquals(Folder.ROOT_FOLDER_ID, note.getFolderId());
}
@Test
public void getNameWithoutPathTest() {
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
// Notes in the root folder
note.setName("noteOnRootFolder");
assertEquals("noteOnRootFolder", note.getNameWithoutPath());
note.setName("/noteOnRootFolderStartsWithSlash");
assertEquals("noteOnRootFolderStartsWithSlash", note.getNameWithoutPath());
// Notes in subdirectories
note.setName("/a/b/note");
assertEquals("note", note.getNameWithoutPath());
note.setName("a/b/note");
assertEquals("note", note.getNameWithoutPath());
}
@Test
public void isTrashTest() {
Note note = new Note(repo, interpreterFactory, jobListenerFactory, index, credentials, noteEventListener);
// Notes in the root folder
note.setName("noteOnRootFolder");
assertFalse(note.isTrash());
note.setName("/noteOnRootFolderStartsWithSlash");
assertFalse(note.isTrash());
// Notes in subdirectories
note.setName("/a/b/note");
assertFalse(note.isTrash());
note.setName("a/b/note");
assertFalse(note.isTrash());
// Notes in trash
note.setName(Folder.TRASH_FOLDER_ID + "/a");
assertTrue(note.isTrash());
note.setName("/" + Folder.TRASH_FOLDER_ID + "/a");
assertTrue(note.isTrash());
note.setName(Folder.TRASH_FOLDER_ID + "/a/b/c");
assertTrue(note.isTrash());
}
}
|
[
"fraczwojciech@gmail.com"
] |
fraczwojciech@gmail.com
|
06e4c59cd46dea7333b1f70d6bc276ff1d0a478c
|
eb97ee5d4f19d7bf028ae9a400642a8c644f8fe3
|
/tags/2010-06-20/seasar2-2.4.42/s2-persistence/src/test/java/org/seasar/persistence/mapper/FieldColumnMapperTest.java
|
0555daa23b32a9f31239a3c9997683f54f82a39a
|
[] |
no_license
|
svn2github/s2container
|
54ca27cf0c1200a93e1cb88884eb8226a9be677d
|
625adc6c4e1396654a7297d00ec206c077a78696
|
refs/heads/master
| 2020-06-04T17:15:02.140847
| 2013-08-09T09:38:15
| 2013-08-09T09:38:15
| 10,850,644
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,414
|
java
|
/*
* Copyright 2004-2007 the Seasar Foundation and the Others.
*
* 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.seasar.persistence.mapper;
import java.lang.reflect.Field;
import junit.framework.TestCase;
import org.seasar.persistence.entity.Employee;
/**
* @author higa
*
*/
public class FieldColumnMapperTest extends TestCase {
/**
* Test method for
* {@link org.seasar.extension.persistence.mapper.FieldPropertyMapper#setValue(java.lang.Object, java.lang.Object[])}.
*
* @throws Exception
*/
public void testSetValue() throws Exception {
Field field = Employee.class.getDeclaredField("id");
field.setAccessible(true);
FieldPropertyMapper mapper = new FieldPropertyMapper(field, 0);
Employee emp = new Employee();
mapper.setValue(emp, new Object[] { new Long(1) });
assertEquals(new Long(1), emp.id);
}
}
|
[
"koichik@319488c0-e101-0410-93bc-b5e51f62721a"
] |
koichik@319488c0-e101-0410-93bc-b5e51f62721a
|
c5d1325904fa7f26aed03ec764dc7427d7922564
|
a1826c2ed9c12cfc395fb1a14c1a2e1f097155cb
|
/ehpc-20180412/src/main/java/com/aliyun/ehpc20180412/models/ListSecurityGroupsResponseBody.java
|
5f71cbaf5a772bb6c39361d970ba60427d2e1a04
|
[
"Apache-2.0"
] |
permissive
|
aliyun/alibabacloud-java-sdk
|
83a6036a33c7278bca6f1bafccb0180940d58b0b
|
008923f156adf2e4f4785a0419f60640273854ec
|
refs/heads/master
| 2023-09-01T04:10:33.640756
| 2023-09-01T02:40:45
| 2023-09-01T02:40:45
| 288,968,318
| 40
| 45
| null | 2023-06-13T02:47:13
| 2020-08-20T09:51:08
|
Java
|
UTF-8
|
Java
| false
| false
| 2,359
|
java
|
// This file is auto-generated, don't edit it. Thanks.
package com.aliyun.ehpc20180412.models;
import com.aliyun.tea.*;
public class ListSecurityGroupsResponseBody extends TeaModel {
/**
* <p>The ID of the request.</p>
*/
@NameInMap("RequestId")
public String requestId;
/**
* <p>The ID of the security group.</p>
*/
@NameInMap("SecurityGroups")
public ListSecurityGroupsResponseBodySecurityGroups securityGroups;
/**
* <p>The number of security groups.</p>
*/
@NameInMap("TotalCount")
public Integer totalCount;
public static ListSecurityGroupsResponseBody build(java.util.Map<String, ?> map) throws Exception {
ListSecurityGroupsResponseBody self = new ListSecurityGroupsResponseBody();
return TeaModel.build(map, self);
}
public ListSecurityGroupsResponseBody setRequestId(String requestId) {
this.requestId = requestId;
return this;
}
public String getRequestId() {
return this.requestId;
}
public ListSecurityGroupsResponseBody setSecurityGroups(ListSecurityGroupsResponseBodySecurityGroups securityGroups) {
this.securityGroups = securityGroups;
return this;
}
public ListSecurityGroupsResponseBodySecurityGroups getSecurityGroups() {
return this.securityGroups;
}
public ListSecurityGroupsResponseBody setTotalCount(Integer totalCount) {
this.totalCount = totalCount;
return this;
}
public Integer getTotalCount() {
return this.totalCount;
}
public static class ListSecurityGroupsResponseBodySecurityGroups extends TeaModel {
@NameInMap("SecurityGroup")
public java.util.List<String> securityGroup;
public static ListSecurityGroupsResponseBodySecurityGroups build(java.util.Map<String, ?> map) throws Exception {
ListSecurityGroupsResponseBodySecurityGroups self = new ListSecurityGroupsResponseBodySecurityGroups();
return TeaModel.build(map, self);
}
public ListSecurityGroupsResponseBodySecurityGroups setSecurityGroup(java.util.List<String> securityGroup) {
this.securityGroup = securityGroup;
return this;
}
public java.util.List<String> getSecurityGroup() {
return this.securityGroup;
}
}
}
|
[
"sdk-team@alibabacloud.com"
] |
sdk-team@alibabacloud.com
|
a326659b1b1a93d43bdd5c530b3a275dd3aba887
|
c9b4e3dd7ef80ac7e1fdf3ccae818ba0d57246eb
|
/stock-day/src/main/java/com/stock/stockday/entity/StockDayYanPanLowLow.java
|
af932d71ae52009e79cc61aaf119c56f867dc972
|
[] |
no_license
|
wuxingle/stock-day
|
104259d3583a5ddbb32d0c79b695999bf1938ab2
|
95ce8201479d3f330fb182ae8b299cabcb171a16
|
refs/heads/master
| 2022-06-27T21:45:17.085292
| 2020-04-13T07:45:36
| 2020-04-13T07:45:36
| 188,746,226
| 0
| 0
| null | 2022-06-21T01:10:29
| 2019-05-27T00:37:23
|
Java
|
UTF-8
|
Java
| false
| false
| 2,810
|
java
|
package com.stock.stockday.entity;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import java.io.Serializable;
import java.math.BigDecimal;
@Data
@TableName("stock_day_yan_pan_low_low")
public class StockDayYanPanLowLow implements Serializable {
private static final long serialVersionUID = 1L;
@TableId
private String id;
private String liangXian;
private String sanXian;
private String siXian;
private String wuXian;
private String kdj;
private String macd;
private String quantityMa;
private String priceMa;
private BigDecimal shangZhangSum1;
private BigDecimal shangZhangMa1;
private BigDecimal shangZhangCount1;
private BigDecimal shangZhangRate1;
private BigDecimal xiaJiangSum1;
private BigDecimal xiaJiangMa1;
private BigDecimal xiaJiangCount1;
private BigDecimal xiaJiangRate1;
private BigDecimal shangZhangSum2;
private BigDecimal shangZhangMa2;
private BigDecimal shangZhangCount2;
private BigDecimal shangZhangRate2;
private BigDecimal xiaJiangSum2;
private BigDecimal xiaJiangMa2;
private BigDecimal xiaJiangCount2;
private BigDecimal xiaJiangRate2;
private BigDecimal shangZhangSum3;
private BigDecimal shangZhangMa3;
private BigDecimal shangZhangCount3;
private BigDecimal shangZhangRate3;
private BigDecimal xiaJiangSum3;
private BigDecimal xiaJiangMa3;
private BigDecimal xiaJiangCount3;
private BigDecimal xiaJiangRate3;
private BigDecimal shangZhangSum5;
private BigDecimal shangZhangMa5;
private BigDecimal shangZhangCount5;
private BigDecimal shangZhangRate5;
private BigDecimal xiaJiangSum5;
private BigDecimal xiaJiangMa5;
private BigDecimal xiaJiangCount5;
private BigDecimal xiaJiangRate5;
private BigDecimal shangZhangSum8;
private BigDecimal shangZhangMa8;
private BigDecimal shangZhangCount8;
private BigDecimal shangZhangRate8;
private BigDecimal xiaJiangSum8;
private BigDecimal xiaJiangMa8;
private BigDecimal xiaJiangCount8;
private BigDecimal xiaJiangRate8;
private BigDecimal shangZhangSum13;
private BigDecimal shangZhangMa13;
private BigDecimal shangZhangCount13;
private BigDecimal shangZhangRate13;
private BigDecimal xiaJiangSum13;
private BigDecimal xiaJiangMa13;
private BigDecimal xiaJiangCount13;
private BigDecimal xiaJiangRate13;
private BigDecimal shangZhangSum20;
private BigDecimal shangZhangMa20;
private BigDecimal shangZhangCount20;
private BigDecimal shangZhangRate20;
private BigDecimal xiaJiangSum20;
private BigDecimal xiaJiangMa20;
private BigDecimal xiaJiangCount20;
private BigDecimal xiaJiangRate20;
}
|
[
"1546752823@qq.com"
] |
1546752823@qq.com
|
b876223cf1d2e35210ad876d81d26600e03cfe40
|
003901a6b3d30751d1ac76798007e4c6830ffb74
|
/udmetrics/src/main/java/com/epam/eco/kafkamanager/udmetrics/utils/MeterTagsComparator.java
|
52aa7ca4005bb9916289572f72a941d1ceac3b08
|
[
"Apache-2.0"
] |
permissive
|
octodemo/eco-kafka-manager
|
45dce4ffe98366ba4784c9538709a1d98bc0c395
|
a4c45edb0b2a7baff2f6ce9ac0a1ec517a1f19f6
|
refs/heads/master
| 2023-04-19T06:44:18.436606
| 2020-05-14T19:42:10
| 2020-05-14T19:42:10
| 264,008,635
| 0
| 0
|
Apache-2.0
| 2021-04-26T20:46:19
| 2020-05-14T19:39:35
|
Java
|
UTF-8
|
Java
| false
| false
| 1,792
|
java
|
/*
* Copyright 2019 EPAM Systems
*
* 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.epam.eco.kafkamanager.udmetrics.utils;
import java.util.ArrayList;
import java.util.Comparator;
import java.util.List;
import io.micrometer.core.instrument.Tag;
import io.micrometer.core.instrument.Tags;
/**
* @author Andrei_Tytsik
*/
public class MeterTagsComparator implements Comparator<Tags> {
public static final MeterTagsComparator INSTANCE = new MeterTagsComparator();
@Override
public int compare(Tags o1, Tags o2) {
if (o1 == o2) {
return 0;
} else if (o2 == null) {
return 1;
} else if (o1 == null) {
return -1;
}
List<Tag> list1 = asList(o1);
List<Tag> list2 = asList(o2);
int result = 0;
for (int i = 0; result == 0 && i < Math.max(list1.size(), list2.size()); i++) {
Tag t1 = i < list1.size() ? list1.get(i) : null;
Tag t2 = i < list2.size() ? list2.get(i) : null;
result = MeterTagComparator.INSTANCE.compare(t1, t2);
}
return result;
}
private static List<Tag> asList(Tags tags) {
List<Tag> list = new ArrayList<>();
tags.forEach(list::add);
return list;
}
}
|
[
"Andrei_Tytsik@epam.com"
] |
Andrei_Tytsik@epam.com
|
b91d3e67e3cc1a3850541bd6fe1e00c58637c23a
|
705879dc61c41198fb2c4f4f6328bba190c8a465
|
/src/main/java/org/virtualbox/IConsoleFindUSBDeviceById.java
|
8e7869d902a8defc62f9ac2c9ea7c04ade8fcd5d
|
[] |
no_license
|
abiquo/hypervisor-mock
|
dcd1d6c8a2fdbc4db01c7a6e9a64edd101e8ed42
|
e49e4ca84930415eca72ab6c73140a0f2eea4bbe
|
refs/heads/master
| 2021-01-19T09:40:57.840712
| 2013-08-23T08:54:17
| 2013-08-23T08:54:17
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,036
|
java
|
package org.virtualbox;
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="_this" type="{http://www.w3.org/2001/XMLSchema}string"/>
* <element name="id" type="{http://www.w3.org/2001/XMLSchema}string"/>
* </sequence>
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
*
*/
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
"_this",
"id"
})
@XmlRootElement(name = "IConsole_findUSBDeviceById")
public class IConsoleFindUSBDeviceById {
@XmlElement(required = true)
protected String _this;
@XmlElement(required = true)
protected String id;
/**
* Gets the value of the this property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getThis() {
return _this;
}
/**
* Sets the value of the this property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setThis(String value) {
this._this = value;
}
/**
* Gets the value of the id property.
*
* @return
* possible object is
* {@link String }
*
*/
public String getId() {
return id;
}
/**
* Sets the value of the id property.
*
* @param value
* allowed object is
* {@link String }
*
*/
public void setId(String value) {
this.id = value;
}
}
|
[
"serafin.sedano@abiquo.com"
] |
serafin.sedano@abiquo.com
|
e83580f6dfb244d50a8ab68451a2d31164c34d30
|
1a4000eb20b564b91e8b7138858f8cc7346d999f
|
/src/main/java/com/threedsoft/user/dto/requests/UserPasswordUpdateRequestDTO.java
|
995ab5e4401b2e1c931f1524fad84fb4e1c8cda8
|
[] |
no_license
|
knpillutla/user-idd
|
b55808cf59774c74562979a56ffefb70ed0e0419
|
9cb06c1c2306704b5a60de3465ed32a650c9e2b1
|
refs/heads/master
| 2020-04-02T15:44:28.694231
| 2019-02-16T20:25:06
| 2019-02-16T20:25:06
| 154,581,622
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 614
|
java
|
package com.threedsoft.user.dto.requests;
import com.fasterxml.jackson.annotation.JsonAutoDetect;
import com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.threedsoft.util.dto.WMSRequestDTO;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
@JsonAutoDetect(fieldVisibility = Visibility.ANY)
@JsonInclude(JsonInclude.Include.NON_DEFAULT)
@NoArgsConstructor
@Data
@AllArgsConstructor
public class UserPasswordUpdateRequestDTO extends WMSRequestDTO{
Long id;
String oldPassword;
String newPassword;
}
|
[
"knpillutla@gmail.com"
] |
knpillutla@gmail.com
|
830ed69f392fa2c6e2fb803705115440f1529ce3
|
982632be3e0d6c66ac3099066f0420313e9c22f5
|
/src/com/xmpp/im/view/IMOutputMsgPicView.java
|
ef98243599c0cc38e2670ad02fe80fc7f94d03a7
|
[] |
no_license
|
liveqmock/IM
|
506a591887e4242ecd1b13809d138e9006ed155b
|
ab4e92b9f0d87947756f3b19c9b12aff9160af68
|
refs/heads/master
| 2020-04-05T18:59:39.399731
| 2014-09-16T16:23:39
| 2014-09-16T16:23:39
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,020
|
java
|
package com.xmpp.im.view;
import android.annotation.SuppressLint;
import android.content.Context;
import android.graphics.Bitmap;
import android.text.TextUtils;
import android.util.AttributeSet;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;
import com.ad.bitmap.BitmapDecodeUtil;
import com.xmpp.im.R;
import com.xmpp.im.model.MessageModel;
/**
*
* @ClassName: IMInputMsgView
* @Description: 输入信息
* @author andy.xu
* @date 2014-9-13 上午11:13:29
*
*/
public class IMOutputMsgPicView extends LinearLayout {
private Context mContext = null;
private ImageView mUserIconView = null;
private TextView mTimeView = null;
private ImageView mReceivePicView = null;
public IMOutputMsgPicView(Context context) {
super(context);
initUI(context);
}
public IMOutputMsgPicView(Context context, AttributeSet attrs) {
super(context, attrs);
initUI(context);
}
@SuppressLint("NewApi")
public IMOutputMsgPicView(Context context, AttributeSet attrs, int defStyle) {
super(context, attrs, defStyle);
initUI(context);
}
private void initUI(final Context context) {
mContext = context;
inflate(context, R.layout.formclient_chat_out_pic, this);
mUserIconView = (ImageView) findViewById(R.id.formclient_row_userid);
mTimeView = (TextView) findViewById(R.id.formclient_row_date);
mReceivePicView = (ImageView) findViewById(R.id.formclient_row_pic);
}
public void onSetMsgData(final MessageModel msg){
if(null == msg)
return;
if(!TextUtils.isEmpty(msg.userIcon)){
new BitmapDecodeUtil().onDisplayBitmap(mUserIconView, msg.userIcon);
}
mTimeView.setText(onGetFormatTime(msg.time));
onSetPic(msg.filePath);
}
private void onSetPic(final String filePath){
if(TextUtils.isEmpty(filePath))
return;
Bitmap bmp = BitmapDecodeUtil.decodeFile(filePath, 360, 640);
if(null != bmp)
mReceivePicView.setImageBitmap(bmp);
}
private String onGetFormatTime(final long time) {
return null;
}
}
|
[
"Administrator@.(none)"
] |
Administrator@.(none)
|
caeb1e930400d5e1ad0d50b8b516cc6b7c459dcb
|
d540f474a7682a30f227db5eb4c5eda30c98870f
|
/src/main/java/com/cloudera/cdp/environments/model/CreateAzureEnvironmentRequestNewNetworkParams.java
|
6ef3c68f80b1a5309fab413621d489fde9532110
|
[
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] |
permissive
|
LeonSun128/cdp-sdk-java
|
91bab049de6cbeb28e526d6996a860e93809250b
|
cfdc5bb268c3dc8bad2370457921099481a1510d
|
refs/heads/master
| 2022-06-03T21:40:22.888055
| 2020-04-08T05:33:16
| 2020-04-08T05:33:16
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,931
|
java
|
/*
* Copyright (c) 2018 Cloudera, Inc. All Rights Reserved.
*
* Portions Copyright (c) Copyright 2013-2018 Amazon.com, Inc. or its
* affiliates. 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.
*/
package com.cloudera.cdp.environments.model;
import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonValue;
import com.cloudera.cdp.client.CdpResponse;
/**
* Parameteres needed to automatically create VNet and Subnets.
**/
@javax.annotation.Generated(value = "com.cloudera.cdp.client.codegen.CdpSDKJavaCodegen", date = "2020-04-07T22:32:18.974-07:00")
public class CreateAzureEnvironmentRequestNewNetworkParams {
/**
* The range of private IPv4 addresses that resources will use under the created VNet.
**/
private String networkCidr = null;
/**
* Getter for networkCidr.
* The range of private IPv4 addresses that resources will use under the created VNet.
**/
@JsonProperty("networkCidr")
public String getNetworkCidr() {
return networkCidr;
}
/**
* Setter for networkCidr.
* The range of private IPv4 addresses that resources will use under the created VNet.
**/
public void setNetworkCidr(String networkCidr) {
this.networkCidr = networkCidr;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
CreateAzureEnvironmentRequestNewNetworkParams createAzureEnvironmentRequestNewNetworkParams = (CreateAzureEnvironmentRequestNewNetworkParams) o;
if (!Objects.equals(this.networkCidr, createAzureEnvironmentRequestNewNetworkParams.networkCidr)) {
return false;
}
return true;
}
@Override
public int hashCode() {
return Objects.hash(networkCidr);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class CreateAzureEnvironmentRequestNewNetworkParams {\n");
sb.append(" networkCidr: ").append(toIndentedString(networkCidr)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line except the first indented by 4 spaces.
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
|
[
"dev-kitchen@cloudera.com"
] |
dev-kitchen@cloudera.com
|
a72a179ddffd060e65358faa453d8b8dd0abea0b
|
97fd02f71b45aa235f917e79dd68b61c62b56c1c
|
/src/main/java/com/tencentcloudapi/tke/v20180525/models/EdgeClusterExtraArgs.java
|
b64b1baaa033f34e18cf840df71bfcfdd1533fea
|
[
"Apache-2.0"
] |
permissive
|
TencentCloud/tencentcloud-sdk-java
|
7df922f7c5826732e35edeab3320035e0cdfba05
|
09fa672d75e5ca33319a23fcd8b9ca3d2afab1ec
|
refs/heads/master
| 2023-09-04T10:51:57.854153
| 2023-09-01T03:21:09
| 2023-09-01T03:21:09
| 129,837,505
| 537
| 317
|
Apache-2.0
| 2023-09-13T02:42:03
| 2018-04-17T02:58:16
|
Java
|
UTF-8
|
Java
| false
| false
| 6,120
|
java
|
/*
* Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. 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.
*/
package com.tencentcloudapi.tke.v20180525.models;
import com.tencentcloudapi.common.AbstractModel;
import com.google.gson.annotations.SerializedName;
import com.google.gson.annotations.Expose;
import java.util.HashMap;
public class EdgeClusterExtraArgs extends AbstractModel{
/**
* kube-apiserver自定义参数,参数格式为["k1=v1", "k1=v2"], 例如["max-requests-inflight=500","feature-gates=PodShareProcessNamespace=true,DynamicKubeletConfig=true"]
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("KubeAPIServer")
@Expose
private String [] KubeAPIServer;
/**
* kube-controller-manager自定义参数
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("KubeControllerManager")
@Expose
private String [] KubeControllerManager;
/**
* kube-scheduler自定义参数
注意:此字段可能返回 null,表示取不到有效值。
*/
@SerializedName("KubeScheduler")
@Expose
private String [] KubeScheduler;
/**
* Get kube-apiserver自定义参数,参数格式为["k1=v1", "k1=v2"], 例如["max-requests-inflight=500","feature-gates=PodShareProcessNamespace=true,DynamicKubeletConfig=true"]
注意:此字段可能返回 null,表示取不到有效值。
* @return KubeAPIServer kube-apiserver自定义参数,参数格式为["k1=v1", "k1=v2"], 例如["max-requests-inflight=500","feature-gates=PodShareProcessNamespace=true,DynamicKubeletConfig=true"]
注意:此字段可能返回 null,表示取不到有效值。
*/
public String [] getKubeAPIServer() {
return this.KubeAPIServer;
}
/**
* Set kube-apiserver自定义参数,参数格式为["k1=v1", "k1=v2"], 例如["max-requests-inflight=500","feature-gates=PodShareProcessNamespace=true,DynamicKubeletConfig=true"]
注意:此字段可能返回 null,表示取不到有效值。
* @param KubeAPIServer kube-apiserver自定义参数,参数格式为["k1=v1", "k1=v2"], 例如["max-requests-inflight=500","feature-gates=PodShareProcessNamespace=true,DynamicKubeletConfig=true"]
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setKubeAPIServer(String [] KubeAPIServer) {
this.KubeAPIServer = KubeAPIServer;
}
/**
* Get kube-controller-manager自定义参数
注意:此字段可能返回 null,表示取不到有效值。
* @return KubeControllerManager kube-controller-manager自定义参数
注意:此字段可能返回 null,表示取不到有效值。
*/
public String [] getKubeControllerManager() {
return this.KubeControllerManager;
}
/**
* Set kube-controller-manager自定义参数
注意:此字段可能返回 null,表示取不到有效值。
* @param KubeControllerManager kube-controller-manager自定义参数
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setKubeControllerManager(String [] KubeControllerManager) {
this.KubeControllerManager = KubeControllerManager;
}
/**
* Get kube-scheduler自定义参数
注意:此字段可能返回 null,表示取不到有效值。
* @return KubeScheduler kube-scheduler自定义参数
注意:此字段可能返回 null,表示取不到有效值。
*/
public String [] getKubeScheduler() {
return this.KubeScheduler;
}
/**
* Set kube-scheduler自定义参数
注意:此字段可能返回 null,表示取不到有效值。
* @param KubeScheduler kube-scheduler自定义参数
注意:此字段可能返回 null,表示取不到有效值。
*/
public void setKubeScheduler(String [] KubeScheduler) {
this.KubeScheduler = KubeScheduler;
}
public EdgeClusterExtraArgs() {
}
/**
* NOTE: Any ambiguous key set via .set("AnyKey", "value") will be a shallow copy,
* and any explicit key, i.e Foo, set via .setFoo("value") will be a deep copy.
*/
public EdgeClusterExtraArgs(EdgeClusterExtraArgs source) {
if (source.KubeAPIServer != null) {
this.KubeAPIServer = new String[source.KubeAPIServer.length];
for (int i = 0; i < source.KubeAPIServer.length; i++) {
this.KubeAPIServer[i] = new String(source.KubeAPIServer[i]);
}
}
if (source.KubeControllerManager != null) {
this.KubeControllerManager = new String[source.KubeControllerManager.length];
for (int i = 0; i < source.KubeControllerManager.length; i++) {
this.KubeControllerManager[i] = new String(source.KubeControllerManager[i]);
}
}
if (source.KubeScheduler != null) {
this.KubeScheduler = new String[source.KubeScheduler.length];
for (int i = 0; i < source.KubeScheduler.length; i++) {
this.KubeScheduler[i] = new String(source.KubeScheduler[i]);
}
}
}
/**
* Internal implementation, normal users should not use it.
*/
public void toMap(HashMap<String, String> map, String prefix) {
this.setParamArraySimple(map, prefix + "KubeAPIServer.", this.KubeAPIServer);
this.setParamArraySimple(map, prefix + "KubeControllerManager.", this.KubeControllerManager);
this.setParamArraySimple(map, prefix + "KubeScheduler.", this.KubeScheduler);
}
}
|
[
"tencentcloudapi@tencent.com"
] |
tencentcloudapi@tencent.com
|
fae0a6dcc890154ce23837cd21c061417d02cda5
|
1a5c12294928a138ab6f140fb53366722c45b7d7
|
/jonix-common/src/main/java/com/tectonica/jonix/codelist/MeasureUnits.java
|
1419b7c987fb850f1441263b32826a27ade82e41
|
[
"Apache-2.0"
] |
permissive
|
francisco-sanchez-molina/jonix
|
831c3df9fd869839ba0fd1cfc783822b1d1d7e0d
|
fceacdb6c03a284862b79c0e96b11e0367d78e31
|
refs/heads/master
| 2021-01-21T03:14:28.259121
| 2016-03-16T10:35:15
| 2016-03-16T10:35:15
| 54,022,300
| 0
| 0
| null | 2016-03-16T10:25:02
| 2016-03-16T10:25:02
| null |
UTF-8
|
Java
| false
| false
| 2,426
|
java
|
/*
* Copyright (C) 2012 Zach Melamed
*
* Latest version available online at https://github.com/zach-m/jonix
* Contact me at zach@tectonica.co.il
*
* 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.tectonica.jonix.codelist;
import java.util.HashMap;
import java.util.Map;
import com.tectonica.jonix.OnixCodelist;
/*
* NOTE: THIS IS AN AUTO-GENERATED FILE, DON'T EDIT MANUALLY
*/
/**
* <code>Enum</code> that corresponds to ONIX <b>Codelist 50</b>
* <p>
* Description: Measure unit code
*
* @see <a href="http://www.editeur.org/14/code-lists">About ONIX Codelists</a>
* @see <a
* href="http://www.editeur.org/files/ONIX%20for%20books%20-%20code%20lists/ONIX_BookProduct_Codelists_Issue_32.html#codelist50">ONIX
* Codelist 50 in Reference Guide</a>
*/
public enum MeasureUnits implements OnixCodelist
{
/**
* Millimeters are the preferred metric unit of length
*/
Centimeters("cm", "Centimeters"), //
Grams("gr", "Grams"), //
Inches_US("in", "Inches (US)"), //
/**
* Grams are the preferred metric unit of weight
*/
Kilograms("kg", "Kilograms"), //
Pounds_US("lb", "Pounds (US)"), //
Millimeters("mm", "Millimeters"), //
Ounces_US("oz", "Ounces (US)"), //
Pixels("px", "Pixels");
public final String code;
public final String description;
private MeasureUnits(String code, String description)
{
this.code = code;
this.description = description;
}
@Override
public String getCode()
{
return code;
}
@Override
public String getDescription()
{
return description;
}
private static Map<String, MeasureUnits> map;
private static Map<String, MeasureUnits> map()
{
if (map == null)
{
map = new HashMap<>();
for (MeasureUnits e : values())
map.put(e.code, e);
}
return map;
}
public static MeasureUnits byCode(String code)
{
if (code == null || code.isEmpty())
return null;
return map().get(code);
}
}
|
[
"zach@tectonica.co.il"
] |
zach@tectonica.co.il
|
a6e69f3e463a9495836179941334684252531ab1
|
a11bc225a7dc3caf8fbf5a59c5fbd4bc96f0051b
|
/mockserver-core/src/main/java/org/mockserver/validator/jsonschema/JsonSchemaExpectationValidator.java
|
d2eb87cc42a3de1559a7ae116a4987e0aef38baf
|
[
"Apache-2.0"
] |
permissive
|
ryomasaber/mockserver
|
9f097c842e25fc0b9d5ef7eea6d19281cda2fef4
|
fb7f1796122a235d349bdd9caa83ae11e696f4cf
|
refs/heads/master
| 2021-05-12T09:36:40.770959
| 2018-01-12T16:47:55
| 2018-01-12T16:47:55
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 943
|
java
|
package org.mockserver.validator.jsonschema;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* @author jamesdbloom
*/
public class JsonSchemaExpectationValidator extends JsonSchemaValidator {
public static Logger logger = LoggerFactory.getLogger(JsonSchemaExpectationValidator.class);
private static String jsonSchema = addReferencesIntoSchema(
"org/mockserver/model/schema/",
"expectation",
"httpRequest",
"httpResponse",
"httpTemplate",
"httpForward",
"httpClassCallback",
"httpObjectCallback",
"httpError",
"times",
"timeToLive",
"body",
"bodyWithContentType",
"delay",
"connectionOptions",
"keyToMultiValue",
"keyToValue"
);
public JsonSchemaExpectationValidator() {
super(jsonSchema);
}
public String getSchema() {
return jsonSchema;
}
}
|
[
"jamesdbloom@gmail.com"
] |
jamesdbloom@gmail.com
|
9cc7f44b95a413b0144ac5b3d0ecad4ec1cfdfb4
|
6fcdd7778809e444d222400cd73625aefd226d39
|
/kubernetes/src/main/java/com/elastisys/scale/cloudpool/kubernetes/podpool/PodPoolSize.java
|
6fdbf4d630c29b5dbe4120eef792246755d3d9a4
|
[
"Apache-2.0"
] |
permissive
|
elastisys/scale.cloudpool
|
4625e3a01dece171777f25d6bcb9b7d82ee18e4a
|
104a2e0f419ba15ff7b7846b35542e7238251f99
|
refs/heads/master
| 2021-04-15T12:32:31.978720
| 2019-05-06T23:47:47
| 2019-05-06T23:47:47
| 21,455,428
| 2
| 5
|
Apache-2.0
| 2021-03-21T09:43:31
| 2014-07-03T08:35:04
|
Java
|
UTF-8
|
Java
| false
| false
| 1,915
|
java
|
package com.elastisys.scale.cloudpool.kubernetes.podpool;
import java.util.Objects;
import com.elastisys.scale.commons.json.JsonUtils;
/**
* Describes both actual and desired size of a {@link PodPool}.
*
* @see PodPool#getSize()
*/
public class PodPoolSize {
/** The number of desired replicas in the {@link PodPool}. */
private final int desiredReplicas;
/** The most recently observed number of replicas in the {@link PodPool}. */
private final int actualReplicas;
/**
* Creates a {@link PodPoolSize}.
*
* @param desiredReplicas
* The number of desired replicas in the {@link PodPool}.
* @param actualReplicas
* The most recently observed number of replicas in the
* {@link PodPool}.
*/
public PodPoolSize(int desiredReplicas, int actualReplicas) {
this.desiredReplicas = desiredReplicas;
this.actualReplicas = actualReplicas;
}
/**
* The number of desired replicas in the {@link PodPool}.
*
* @return
*/
public int getDesiredReplicas() {
return this.desiredReplicas;
}
/**
* The most recently observed number of replicas in the {@link PodPool}.
*
* @return
*/
public int getActualReplicas() {
return this.actualReplicas;
}
@Override
public int hashCode() {
return Objects.hash(this.desiredReplicas, this.actualReplicas);
}
@Override
public boolean equals(Object obj) {
if (obj instanceof PodPoolSize) {
PodPoolSize that = (PodPoolSize) obj;
return Objects.equals(this.desiredReplicas, that.desiredReplicas) //
&& Objects.equals(this.actualReplicas, that.actualReplicas);
}
return false;
}
@Override
public String toString() {
return JsonUtils.toString(JsonUtils.toJson(this));
}
}
|
[
"peter.gardfjall.work@gmail.com"
] |
peter.gardfjall.work@gmail.com
|
47c6f88a1bc4383d6d031a7b4856c1346fc146a2
|
ce54a65bd0a1206b49adcdc8706b114dc5c60dc8
|
/src/main/java/com/xcs/phase2/model/lawsult/LawsuitArrestIndictment.java
|
ed39aae30f1937bdbc05ed8fd81cc028d15ea5e8
|
[] |
no_license
|
Sitta-Dev/Excise_API
|
d961fa215ef59ed13b5749b010563e07bf00516c
|
c1657a342ac759e7acf8eae60a2c4ceefba73098
|
refs/heads/master
| 2023-01-13T12:05:50.060374
| 2020-11-19T05:58:08
| 2020-11-19T05:58:08
| 285,178,533
| 0
| 1
| null | 2020-08-05T09:22:54
| 2020-08-05T04:26:09
|
Java
|
UTF-8
|
Java
| false
| false
| 3,315
|
java
|
package com.xcs.phase2.model.lawsult;
import java.util.List;
import lombok.Data;
@Data
public class LawsuitArrestIndictment extends LawsultModel {
private int INDICTMENT_ID;
private int ARREST_ID;
private String ARREST_CODE;
private String OCCURRENCE_DATE;
private String ARREST_OFFICE_NAME;
private String ACCUSER_TITLE_NAME_TH;
private String ACCUSER_TITLE_NAME_EN;
private String ACCUSER_TITLE_SHORT_NAME_TH;
private String ACCUSER_TITLE_SHORT_NAME_EN;
private String ACCUSER_FIRST_NAME;
private String ACCUSER_LAST_NAME;
private String ACCUSER_OPERATION_POS_CODE;
private String ACCUSER_OPREATION_POS_NAME;
private String ACCUSER_OPREATION_POS_LEVEL;
private String ACCUSER_OPERATION_POS_LEVEL_NAME;
private String ACCUSER_OPERATION_DEPT_CODE;
private String ACCUSER_OPERATION_DEPT_NAME;
private int ACCUSER_OPERATION_DEPT_LEVEL;
private String ACCUSER_OPERATION_UNDER_DEPT_CODE;
private String ACCUSER_OPERATION_UNDER_DEPT_NAME;
private int ACCUSER_OPERATION_UNDER_DEPT_LEVEL;
private String ACCUSER_OPERATION_WORK_DEPT_CODE;
private String ACCUSER_OPERATION_WORK_DEPT_NAME;
private int ACCUSER_OPERATION_WORK_DEPT_LEVEL;
private String ACCUSER_OPERATION_OFFICE_CODE;
private String ACCUSER_OPERATION_OFFICE_NAME;
private String ACCUSER_OPERATION_OFFICE_SHORT_NAME;
private String ACCUSER_MANAGEMENT_POS_CODE;
private String ACCUSER_MANAGEMENT_POS_NAME;
private String ACCUSER_MANAGEMENT_POS_LEVEL;
private String ACCUSER_MANAGEMENT_POS_LEVEL_NAME;
private String ACCUSER_MANAGEMENT_DEPT_CODE;
private String ACCUSER_MANAGEMENT_DEPT_NAME;
private int ACCUSER_MANAGEMENT_DEPT_LEVEL;
private String ACCUSER_MANAGEMENT_UNDER_DEPT_CODE;
private String ACCUSER_MANAGEMENT_UNDER_DEPT_NAME;
private int ACCUSER_MANAGEMENT_UNDER_DEPT_LEVEL;
private String ACCUSER_MANAGEMENT_WORK_DEPT_CODE;
private String ACCUSER_MANAGEMENT_WORK_DEPT_NAME;
private int ACCUSER_MANAGEMENT_WORK_DEPT_LEVEL;
private String ACCUSER_MANAGEMENT_OFFICE_CODE;
private String ACCUSER_MANAGEMENT_OFFICE_NAME;
private String ACCUSER_MANAGEMENT_OFFICE_SHORT_NAME;
private String ACCUSER_REPRESENT_POS_CODE;
private String ACCUSER_REPRESENT_POS_NAME;
private String ACCUSER_REPRESENT_POS_LEVEL;
private String ACCUSER_REPRESENT_POS_LEVEL_NAME;
private String ACCUSER_REPRESENT_DEPT_CODE;
private String ACCUSER_REPRESENT_DEPT_NAME;
private int ACCUSER_REPRESENT_DEPT_LEVEL;
private String ACCUSER_REPRESENT_UNDER_DEPT_CODE;
private String ACCUSER_REPRESENT_UNDER_DEPT_NAME;
private int ACCUSER_REPRESENT_UNDER_DEPT_LEVEL;
private String ACCUSER_REPRESENT_WORK_DEPT_CODE;
private String ACCUSER_REPRESENT_WORK_DEPT_NAME;
private int ACCUSER_REPRESENT_WORK_DEPT_LEVEL;
private String ACCUSER_REPRESENT_OFFICE_CODE;
private String ACCUSER_REPRESENT_OFFICE_NAME;
private String ACCUSER_REPRESENT_OFFICE_SHORT_NAME;
private String GUILTBASE_NAME;
private String FINE;
private int IS_PROVE;
private int IS_COMPARE;
private String SUBSECTION_NAME;
private String SUBSECTION_DESC;
private String SECTION_NAME;
private String PENALTY_DESC;
private List<LawsuitArrestIndictmentProduct> LawsuitArrestIndictmentProduct;
private List<LawsuitArrestIndictmentDetail> LawsuitArrestIndictmentDetail;
private List<LawsuitNotice> LawsuitNotice;
private List<LawsuitLocale> LawsuitLocale;
}
|
[
"bakugan_chun@hotmail.com"
] |
bakugan_chun@hotmail.com
|
0bfff757af4a48844078cab03641d4ccac8f394b
|
7c2f5bdf6199ee25afafbc8bc2eb77541976d00e
|
/Bukkit/src/main/java/io/riguron/bukkit/gui/multipage/MultiPageListener.java
|
b70c939f091341d47eca70bdc771c17ebc0bce95
|
[
"MIT"
] |
permissive
|
Stijn-van-Nieulande/MinecraftNetwork
|
0995d2fad0f7e1150dff0394c2568d9e8f6d1dca
|
7ed43098a5ba7574e2fb19509e363c3cf124fc0b
|
refs/heads/master
| 2022-04-03T17:48:42.635003
| 2020-01-22T05:22:49
| 2020-01-22T05:22:49
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,959
|
java
|
package io.riguron.bukkit.gui.multipage;
import lombok.RequiredArgsConstructor;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.inventory.InventoryClickEvent;
import org.bukkit.event.inventory.InventoryCloseEvent;
import org.bukkit.event.player.PlayerQuitEvent;
import org.bukkit.inventory.ItemStack;
import io.riguron.bukkit.gui.multipage.player.PlayerPages;
import java.util.UUID;
import static io.riguron.bukkit.gui.multipage.MultiPageButtons.NEXT_PAGE;
import static io.riguron.bukkit.gui.multipage.MultiPageButtons.PREVIOUS_PAGE;
@RequiredArgsConstructor
public class MultiPageListener implements Listener {
private final PageSwitcher pageSwitcher;
private final SlotActions slotActions;
private final PlayerPages playerPages;
@EventHandler
public void inventoryClicked(InventoryClickEvent e) {
if (playerPages.hasSession(e.getWhoClicked().getUniqueId())) {
e.setCancelled(true);
ItemStack currentItem = e.getCurrentItem();
if (currentItem != null) {
handleItemClick(e, currentItem);
}
}
}
@EventHandler
public void inventoryClosed(InventoryCloseEvent e) {
playerPages.removePlayer(e.getPlayer().getUniqueId());
}
@EventHandler
public void quit(PlayerQuitEvent event) {
playerPages.removePlayer(event.getPlayer().getUniqueId());
}
private void handleItemClick(InventoryClickEvent event, ItemStack currentItem) {
UUID uuid = event.getWhoClicked().getUniqueId();
if (NEXT_PAGE.getItemStack().equals(currentItem)) {
this.pageSwitcher.switchPage(uuid, operand -> operand + 1);
} else if (PREVIOUS_PAGE.getItemStack().equals(currentItem)) {
this.pageSwitcher.switchPage(uuid, operand -> operand - 1);
} else {
slotActions.executeSlotAction(uuid, event.getSlot());
}
}
}
|
[
"25826296+riguron@users.noreply.github.com"
] |
25826296+riguron@users.noreply.github.com
|
7a3b19f0f5dd9aafffeaf1cc8bad58a3e4f6d406
|
e4263b6346c2ad1cda131b9c7d53adc6f72c67e4
|
/tcamt-domain/src/main/java/gov/nist/healthcare/tools/hl7/v2/igamt/lite/domain/SegmentLink.java
|
e6af5a5f31dc617ac96c7c8b89827c2da9ee113c
|
[] |
no_license
|
usnistgov/tcamt
|
df10682375a8b6dd255fcb126a9068fe4a44fd56
|
194e582b1bf3decd78f59c0c618aaabf87f04325
|
refs/heads/master
| 2020-05-21T04:48:44.575571
| 2019-02-20T18:43:38
| 2019-02-20T18:43:38
| 47,419,732
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,852
|
java
|
/**
* This software was developed at the National Institute of Standards and Technology by employees of
* the Federal Government in the course of their official duties. Pursuant to title 17 Section 105
* of the United States Code this software is not subject to copyright protection and is in the
* public domain. This is an experimental system. NIST assumes no responsibility whatsoever for its
* use by other parties, and makes no guarantees, expressed or implied, about its quality,
* reliability, or any other characteristic. We would appreciate acknowledgement if the software is
* used. This software can be redistributed and/or modified freely provided that any derivative
* works bear some notice that they are derived from it, and any modified versions bear some notice
* that they have been modified.
*/
package gov.nist.healthcare.tools.hl7.v2.igamt.lite.domain;
/**
* @author gcr1
*
*/
public class SegmentLink extends AbstractLink implements Cloneable, Comparable<SegmentLink> {
private String name;
private String ext;
public SegmentLink() {
super();
}
public SegmentLink(String id, String name, String ext) {
super();
this.setId(id);
this.ext = ext;
this.name = name;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getExt() {
return ext;
}
public void setExt(String ext) {
this.ext = ext;
}
public String getLabel() {
return name + (ext != null ? "_" + ext : "");
}
@Override
public int hashCode() {
final int prime = 31;
int result = 1;
result = prime * result + ((id == null) ? 0 : id.hashCode());
return result;
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (getClass() != obj.getClass())
return false;
SegmentLink other = (SegmentLink) obj;
if (id == null) {
if (other.id != null)
return false;
} else if (!id.equals(other.id))
return false;
return true;
}
public SegmentLink clone() {
SegmentLink clonedLink = new SegmentLink();
clonedLink.setExt(this.ext);
clonedLink.setName(this.name);
clonedLink.setId(this.getId());
return clonedLink;
}
public int compareTo(SegmentLink o) {
int x =
String.CASE_INSENSITIVE_ORDER.compare(this.getLabel() != null ? this.getLabel() : "",
o.getLabel() != null ? o.getLabel() : "");
if (x == 0) {
x =
(this.getLabel() != null ? this.getLabel() : "").compareTo(o.getLabel() != null ? o
.getLabel() : "");
}
return x;
}
@Override
public String toString() {
return "SegmentLink [id=" + id + ", name=" + name + ", ext=" + ext + ", label= " + getLabel()
+ "]";
}
}
|
[
"jungyub.woo@nist.gov"
] |
jungyub.woo@nist.gov
|
28227098cc40ee3bac97858f062be895b1fed2e1
|
e06900d3d17dda04b734dd0d34f03198f475e182
|
/eventstorm-sql/src/main/java/eu/eventstorm/sql/expression/JsonPathFieldOperation.java
|
08d7a7469b743b9fcf3fdc1d149fedc84822b4b5
|
[
"Apache-2.0"
] |
permissive
|
eventstorm-projects/eventstorm
|
d65168c4abe57459fa88222b91a23382ebf7cbfe
|
dca116f6eb386511e934572ce61d39a3b09d8387
|
refs/heads/master
| 2023-08-30T22:52:54.193613
| 2023-08-25T11:48:48
| 2023-08-25T11:48:48
| 208,010,054
| 0
| 3
|
Apache-2.0
| 2023-07-09T22:07:30
| 2019-09-12T09:11:43
|
Java
|
UTF-8
|
Java
| false
| false
| 194
|
java
|
package eu.eventstorm.sql.expression;
/**
* @author <a href="mailto:jacques.militello@gmail.com">Jacques Militello</a>
*/
public enum JsonPathFieldOperation {
EQUALS, GREATER, LESSER
}
|
[
"jacques.militello@gmail.com"
] |
jacques.militello@gmail.com
|
62706fed36afed023334da4c126804597db0fb1b
|
dede6aaca13e69cb944986fa3f9485f894444cf0
|
/media-hapi/src/main/java/com/dangdang/digital/service/IDigestService.java
|
bd7ad5757dd189cbbb797ce63becba98f42d3c18
|
[] |
no_license
|
summerxhf/dang
|
c0d1e7c2c9436a7c7e7f9c8ef4e547279ec5d441
|
f1b459937d235637000fb433919a7859dcd77aba
|
refs/heads/master
| 2020-03-27T08:32:33.743260
| 2015-06-03T08:12:45
| 2015-06-03T08:12:45
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,517
|
java
|
/**
* Description: IDigestService.java
* All Rights Reserved.
* @version 1.0 2015年1月22日 下午3:00:30 by 代鹏(daipeng@dangdang.com)创建
*/
package com.dangdang.digital.service;
import java.util.Collection;
import java.util.Date;
import java.util.List;
import com.dangdang.digital.model.Digest;
/**
* Description:
* All Rights Reserved.
* @version 1.0 2015年1月22日 下午3:00:30 by 代鹏(daipeng@dangdang.com)创建
*/
public interface IDigestService extends IBaseService<Digest, Long> {
int insert(Digest record);
int updateDigest(Digest record);
int delete(Long id);
Digest findDigestById(Long id);
List<Digest> queryDigestsByIdsAndSortByIds(Collection<Long> ids, Integer offSet, Integer pageSize);
List<Digest> queryDigestsByIds(Collection<Long> ids, Date lastDate, Integer pageSize);
List<Digest> queryDigestsByMood(Integer mood, Date lastDate, Integer pageSize);
/**
* Description: 从DB中取某一日期,白天黑夜的精品列表
* @Version1.0 2015年1月26日 下午5:47:00 by 代鹏(daipeng@dangdang.com)创建
* @param currentPageDate:yyyy-MM-dd
* @param dayOrNight
* @return
*/
List<Digest> queryDigestsListForDB(String currentPageDate, Integer dayOrNight)throws Exception;
/**
* Description: 先从缓存中取某一日期,白天黑夜的精品列表,若没有再取DB并入缓存
* @Version1.0 2015年1月26日 下午5:47:45 by 代鹏(daipeng@dangdang.com)创建
* @param currentPageDate:yyyy-MM-dd
* @param dayOrNight
* @return
*/
List<Digest> queryDigestHomePageList(String currentPageDate, Integer dayOrNight)throws Exception;
/**
* Description: 根据时间段以及白天黑夜查询
* @Version1.0 2015年1月28日 下午5:06:59 by 代鹏(daipeng@dangdang.com)创建
* @param startDate
* @param endDate
* @param dayOrNight
* @return
*/
List<Digest> queryDigestListByDateSlotAndDayOrNight(Date startDate, Date endDate, Integer dayOrNight);
/**
* Description: 小于展示时间showEndDate,且取最新一条记录
* @Version1.0 2015年1月29日 下午2:28:27 by 代鹏(daipeng@dangdang.com)创建
* @param showEndDate
* @param dayOrNight
* @return
*/
Digest getDigestByShowEndDateLimitOne(Date showEndDate, Integer dayOrNight);
/**
* Description: 根据id取精品正文内容以及展示类型
* @Version1.0 2015年1月31日 下午2:51:49 by 代鹏(daipeng@dangdang.com)创建
* @param id
* @return
*/
Digest getDigestContentById(Long id);
/**
* Description: 根据标签id查询对应的精品列表
* @Version1.0 2015年2月9日 下午4:46:21 by 代鹏(daipeng@dangdang.com)创建
* @param signId
* @param lasteDate
* @param pageSize
* @return
*/
List<Digest> queryDigestsBySignId(Long signId, Date lasteDate, Integer pageSize);
/**
* Description: 根据作者id查询对应的精品列表
* @Version1.0 2015年2月9日 下午4:46:11 by 代鹏(daipeng@dangdang.com)创建
* @param authorId
* @param lasteDate
* @param pageSize
* @return
*/
List<Digest> queryDigestsByAuthorId(Long authorId, Date lasteDate, Integer pageSize);
/**
* Description: 获取个人收藏精品文章列表
* @Version1.0 2015年3月11日 下午3:31:50 by 代鹏(daipeng@dangdang.com)创建
* @param custId
* @param storeType
* @param platForm
* @param offSet
* @param pageSize
* @return
*/
List<Digest> queryDigestsByStoreUpAndCustId(Long custId, String storeType, String platForm, Integer offSet, Integer pageSize);
/**
* Description: 下拉获取最新的首页内容
* @Version1.0 2015年3月17日 下午3:29:26 by 代鹏(daipeng@dangdang.com)创建
* @param sortPage
* @param dayOrNight
* @param pageSize
* @return
*/
List<Digest> queryDigestsHomePageNew(Long sortPage, Integer dayOrNight, Integer pageSize, Integer type);
/**
* Description: 上拉获取首页旧内容
* @Version1.0 2015年3月17日 下午3:29:55 by 代鹏(daipeng@dangdang.com)创建
* @param sortPage
* @param dayOrNight
* @param pageSize
* @param type
* @return
*/
List<Digest> queryDigestsHomePageOld(Long sortPage, Integer dayOrNight, Integer pageSize, Integer type);
/**
* Description: 一篇儿文章id
* @Version1.0 2015年4月13日 下午3:53:19 by 代鹏(daipeng@dangdang.com)创建
* @param dayOrNight
* @param start
* @param end
* @return
*/
Long getDigestIdtWithOne(Integer dayOrNight, Date start, Date end) throws Exception;
}
|
[
"maqiang@dangdang.com"
] |
maqiang@dangdang.com
|
0b8f1e470b62cb9b549b5f76b132a8ac9574aa60
|
372416d9f857580b253c418a754c1cdfb01cc3ab
|
/src/main/java/com/yves/lambert/dao/ListeCoursesDAO.java
|
bf25401a7975b999eb51bddd2428c255a170cc0d
|
[] |
no_license
|
Yvs08/CRUD-Hibernate-Jpa-spring-JSP
|
0f9d0eb9cae81d6974e2e7d02d07ffc274aa425c
|
a969436fad8291b1cf4b0620ecad97688f0fa13e
|
refs/heads/master
| 2021-01-18T22:40:53.190019
| 2016-06-28T11:29:51
| 2016-06-28T11:29:51
| 62,135,375
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,694
|
java
|
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package com.yves.lambert.dao;
import java.util.List;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;
import javax.persistence.TypedQuery;
import javax.persistence.criteria.CriteriaBuilder;
import javax.persistence.criteria.CriteriaQuery;
import javax.persistence.criteria.Root;
import org.springframework.stereotype.Repository;
import bean.Course;
import javax.persistence.Query;
import javax.persistence.criteria.CriteriaUpdate;
import javax.persistence.criteria.Expression;
import javax.persistence.criteria.Path;
@Repository
public class ListeCoursesDAO implements IListeCoursesDAO {
@PersistenceContext
private EntityManager entityManager;
public List<Course> rechercherCourses() {
final CriteriaBuilder lCriteriaBuilder = entityManager.getCriteriaBuilder();
final CriteriaQuery<Course> lCriteriaQuery = lCriteriaBuilder.createQuery(Course.class);
final Root<Course> lRoot = lCriteriaQuery.from(Course.class);
lCriteriaQuery.select(lRoot);
final TypedQuery<Course> lTypedQuery = entityManager.createQuery(lCriteriaQuery);
return lTypedQuery.getResultList();
}
public void creerCourse(final Course pCourse) {
entityManager.persist(pCourse);
}
public void supprimerCourse(final Course pCourse) {
final Course lCourse = entityManager.getReference(Course.class, pCourse.getId());
entityManager.remove(lCourse);
}
public void modifierCourse(final Course pCourse) {
final CriteriaBuilder lCriteriaBuilder = entityManager.getCriteriaBuilder();
final CriteriaUpdate<Course> lCriteriaUpdate = lCriteriaBuilder.createCriteriaUpdate(Course.class);
final Root<Course> lRoot = lCriteriaUpdate.from(Course.class);
final Path<Course> lPath = lRoot.get("id");
final Expression<Boolean> lExpression = lCriteriaBuilder.equal(lPath, pCourse.getId());
lCriteriaUpdate.where(lExpression);
lCriteriaUpdate.set("quantite", pCourse.getQuantite());
final Query lQuery = entityManager.createQuery(lCriteriaUpdate);
final int lRowCount = lQuery.executeUpdate();
if (lRowCount != 1) {
final org.hibernate.Query lHQuery = lQuery.unwrap(org.hibernate.Query.class);
final String lSql = lHQuery.getQueryString();
throw new RuntimeException("Nombre d'occurences (" + lRowCount
+ ") modifiés différent de 1 pour " + lSql);
}
}
}
|
[
"you@example.com"
] |
you@example.com
|
e5727edb4d4e0c52e5990fa5977f26e8fecedb13
|
0d21ea12e8188a86b61c215332500f9ccb7aa66d
|
/ttt-ttv/src/main/java/com/skynav/ttv/verifier/ttml/metadata/AgentAttributeVerifier.java
|
d3ee09304d78826782a194f31c84a25393cf23ab
|
[
"BSD-2-Clause"
] |
permissive
|
skynav/ttt
|
9633e9cd7c2cab93440ea3064b07e4c4bb583804
|
ed39b2f17af3bd20fcabd761a7424bfc0e949e19
|
refs/heads/master
| 2022-11-23T17:14:24.379748
| 2022-10-18T17:09:21
| 2022-10-18T17:09:21
| 34,235,135
| 81
| 17
|
BSD-2-Clause
| 2022-10-18T17:09:22
| 2015-04-20T03:09:58
|
Java
|
UTF-8
|
Java
| false
| false
| 3,556
|
java
|
/*
* Copyright 2013-2015 Skynav, Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 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.
*
* THIS SOFTWARE IS PROVIDED BY SKYNAV, INC. AND ITS CONTRIBUTORS “AS IS” AND ANY
* EXPRESS 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 SKYNAV, INC. 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.
*/
package com.skynav.ttv.verifier.ttml.metadata;
import java.util.List;
import java.util.Set;
import javax.xml.namespace.QName;
import org.w3c.dom.Node;
import com.skynav.ttv.model.Model;
import com.skynav.ttv.util.Location;
import com.skynav.ttv.util.Reporter;
import com.skynav.ttv.verifier.MetadataValueVerifier;
import com.skynav.ttv.verifier.VerifierContext;
import com.skynav.ttv.verifier.util.Agents;
import com.skynav.ttv.verifier.util.IdReferences;
public class AgentAttributeVerifier implements MetadataValueVerifier {
public boolean verify(Object value, Location location, VerifierContext context) {
boolean failed = false;
Model model = context.getModel();
QName name = location.getAttributeName();
QName targetName = model.getIdReferenceTargetName(name);
Class<?> targetClass = model.getIdReferenceTargetClass(name);
List<List<QName>> ancestors = model.getIdReferencePermissibleAncestors(name);
assert value instanceof List<?>;
List<?> agents = (List<?>) value;
if (agents.size() > 0) {
Set<String> agentIdentifiers = new java.util.HashSet<String>();
for (Object agent : agents) {
Node node = context.getXMLNode(agent);
if (!Agents.isAgentReference(node, agent, location, context, targetClass, ancestors)) {
Agents.badAgentReference(node, agent, location, context, name, targetName, targetClass, ancestors);
failed = true;
}
String id = IdReferences.getId(agent);
if (agentIdentifiers.contains(id)) {
Reporter reporter = context.getReporter();
if (reporter.isWarningEnabled("duplicate-idref-in-agent")) {
if (reporter.logWarning(reporter.message(location.getLocator(),
"*KEY*", "Duplicate IDREF ''{0}'' in ''{1}''.", IdReferences.getId(agent), name))) {
failed = true;
}
}
} else
agentIdentifiers.add(id);
}
}
return !failed;
}
}
|
[
"glenn@skynav.com"
] |
glenn@skynav.com
|
09d74d1006f985f4fc80bc7711c472e4ea05b5ff
|
c2b6d71cf79dfe4d3b20c3978f48e8b24f3a252a
|
/July9_30AMSeleniumBatch/src/com/webdrivescreenshots/Screenshot3.java
|
3413853b1d11f45578370c8c4c10b9f1f331b5e2
|
[] |
no_license
|
NazShaan/July9_30AM_Repo
|
c701d7e1f70b0bd2f2c492404240a8d2552f99ad
|
6d84f16923ba8319f772173e9a18b399f7616bb3
|
refs/heads/master
| 2022-12-20T18:50:44.933452
| 2020-10-06T01:23:54
| 2020-10-06T01:23:54
| 290,602,841
| 0
| 0
| null | 2020-08-26T20:55:29
| 2020-08-26T20:55:28
| null |
UTF-8
|
Java
| false
| false
| 1,214
|
java
|
package com.webdrivescreenshots;
import java.io.File;
import java.util.List;
import org.openqa.selenium.By;
import org.openqa.selenium.OutputType;
import org.openqa.selenium.TakesScreenshot;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.io.FileHandler;
public class Screenshot3
{
public static void main(String[] args) throws Exception
{
System.setProperty("webdriver.chrome.driver", "C:\\Users\\DELL\\Desktop\\JulyDrivers\\chromedriver.exe");
WebDriver driver = new ChromeDriver();
driver.manage().window().maximize();
driver.get("https://google.com");
List<WebElement> links=driver.findElements(By.tagName("a"));
for(int i=0;i<links.size();i++)
{
if(!links.get(i).getText().isEmpty())
{
String linkname=links.get(i).getText();
links.get(i).click();
File srcFile=((TakesScreenshot)driver).getScreenshotAs(OutputType.FILE);
FileHandler.copy(srcFile,new File("C:\\Users\\DELL\\Desktop\\Screenshots1234\\"+linkname+".jpeg"));
driver.navigate().back();
Thread.sleep(3000);
links=driver.findElements(By.tagName("a"));
}
}
}
}
|
[
"maha@gmail.com"
] |
maha@gmail.com
|
a67fd9a1999b548f200a4134800a56883fc93d4c
|
cfafe0dc3d67eb22e658ccb43e8d8744cade353c
|
/src/com/codechef/practice/easy/year2015/may/DecreasingString.java
|
65c42691150e4c018449793cb84341c84592c070
|
[] |
no_license
|
drexdelta/Competitive-Programming
|
d07031a3291fcebd95ee536151dd96e31670c9af
|
927bb31cde62678fd2bbf2de30401bdcb3bcc9a9
|
refs/heads/master
| 2021-01-12T12:10:13.986881
| 2016-10-20T20:52:27
| 2016-10-20T20:52:27
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 6,324
|
java
|
package com.codechef.practice.easy.year2015.may;
import java.io.BufferedWriter;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.io.Writer;
import java.util.InputMismatchException;
class DecreasingString
{
private static int t, k;
private static char letters[];
private static InputReader reader;
private static OutputWriter writer;
public static void main(String[] args)
{
DecreasingString dec = new DecreasingString();
reader = dec.new InputReader(System.in);
writer = dec.new OutputWriter(System.out);
// System.out.println((int) 'a' + " " + (int) 'z');
getAttributes();
writer.flush();
reader.close();
writer.close();
}
public static void getAttributes()
{
StringBuilder answer;
int temp;
t = reader.nextInt();
letters = new char[26];
for (int i = 0; i < 26; i++)
letters[i] = (char) (97 + i);
// System.out.println(Arrays.toString(letters));
// System.out.println("add(0, 25) : " + add(25, 0));
for (int i = 0; i < t; i++)
{
k = reader.nextInt();
answer = new StringBuilder();
temp = k % 25;
if (temp > 0)
answer.append(add(temp, 0));
if (k >= 25)
{
temp = k / 25;
while (temp > 0)
{
answer.append(add(25, 0));
temp--;
}
}
writer.println(answer.toString());
}
}
public static String add(int from, int to)
{
String ans = "";
for (int i = from; i >= to; i--)
ans += letters[i];
return ans;
}
class InputReader
{
private InputStream stream;
private byte[] buf = new byte[1024];
private int curChar;
private int numChars;
public InputReader(InputStream stream)
{
this.stream = stream;
}
public int read()
{
if (numChars == -1)
throw new InputMismatchException();
if (curChar >= numChars)
{
curChar = 0;
try
{
numChars = stream.read(buf);
}
catch (IOException e)
{
throw new InputMismatchException();
}
if (numChars <= 0)
return -1;
}
return buf[curChar++];
}
public int nextInt()
{
int c = read();
while (isSpaceChar(c))
c = read();
int sgn = 1;
if (c == '-')
{
sgn = -1;
c = read();
}
int res = 0;
do
{
if (c < '0' || c > '9')
throw new InputMismatchException();
res *= 10;
res += c & 15;
c = read();
} while (!isSpaceChar(c));
return res * sgn;
}
public long nextLong()
{
int c = read();
while (isSpaceChar(c))
c = read();
int sign = 1;
if (c == '-')
{
sign = -1;
c = read();
}
long result = 0;
do
{
if (c < '0' || c > '9')
throw new InputMismatchException();
result *= 10;
result += c & 15;
c = read();
} while (!isSpaceChar(c));
return result * sign;
}
public float nextFloat() // problematic
{
float result, div;
byte c;
result = 0;
div = 1;
c = (byte) read();
while (c <= ' ')
c = (byte) read();
boolean isNegative = (c == '-');
if (isNegative)
c = (byte) read();
do
{
result = result * 10 + c - '0';
} while ((c = (byte) read()) >= '0' && c <= '9');
if (c == '.')
while ((c = (byte) read()) >= '0' && c <= '9')
result += (c - '0') / (div *= 10);
if (isNegative)
return -result;
return result;
}
public double nextDouble() // not completely accurate
{
double ret = 0, div = 1;
byte c = (byte) read();
while (c <= ' ')
c = (byte) read();
boolean neg = (c == '-');
if (neg)
c = (byte) read();
do
{
ret = ret * 10 + c - '0';
} while ((c = (byte) read()) >= '0' && c <= '9');
if (c == '.')
while ((c = (byte) read()) >= '0' && c <= '9')
ret += (c - '0') / (div *= 10);
if (neg)
return -ret;
return ret;
}
public String next()
{
int c = read();
while (isSpaceChar(c))
c = read();
StringBuilder res = new StringBuilder();
do
{
res.appendCodePoint(c);
c = read();
} while (!isSpaceChar(c));
return res.toString();
}
public boolean isSpaceChar(int c)
{
return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
}
public void close()
{
try
{
stream.close();
}
catch (IOException e)
{
e.printStackTrace();
}
}
}
class OutputWriter
{
private PrintWriter writer;
public OutputWriter(OutputStream stream)
{
writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(
stream)));
}
public OutputWriter(Writer writer)
{
this.writer = new PrintWriter(writer);
}
public void println(int x)
{
writer.println(x);
}
public void print(int x)
{
writer.print(x);
}
public void println(int array[], int size)
{
for (int i = 0; i < size; i++)
println(array[i]);
}
public void print(int array[], int size)
{
for (int i = 0; i < size; i++)
print(array[i] + " ");
}
public void println(long x)
{
writer.println(x);
}
public void print(long x)
{
writer.print(x);
}
public void println(long array[], int size)
{
for (int i = 0; i < size; i++)
println(array[i]);
}
public void print(long array[], int size)
{
for (int i = 0; i < size; i++)
print(array[i]);
}
public void println(float num)
{
writer.println(num);
}
public void print(float num)
{
writer.print(num);
}
public void println(double num)
{
writer.println(num);
}
public void print(double num)
{
writer.print(num);
}
public void println(String s)
{
writer.println(s);
}
public void print(String s)
{
writer.print(s);
}
public void println()
{
writer.println();
}
public void printSpace()
{
writer.print(" ");
}
public void flush()
{
writer.flush();
}
public void close()
{
writer.close();
}
}
}
|
[
"rahulkhairwar@gmail.com"
] |
rahulkhairwar@gmail.com
|
b7553145f4fe4bec291e6a5254e89838459edd1d
|
f24971da11abd8baa2007952f3291f4cae145810
|
/Product/Production/Common/AurionCoreLib/src/main/java/org/alembic/aurion/patientdiscovery/nhin/proxy/NhinPatientDiscoveryNoOpImpl.java
|
1d83024661274f2713f327404529e0f135e2563e
|
[] |
no_license
|
AurionProject/Aurion_4.1
|
88e912dd0f688dea2092c80aff3873ad438d5aa9
|
db21f7fe860550baa7942c1d78e49eab3ece82db
|
refs/heads/master
| 2021-01-17T15:41:34.372017
| 2015-12-21T21:09:42
| 2015-12-21T21:09:42
| 49,459,325
| 0
| 2
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 891
|
java
|
/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright 2010(Year date of delivery) United States Government, as represented by the Secretary of Health and Human Services. All rights reserved.
*
*/
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package org.alembic.aurion.patientdiscovery.nhin.proxy;
import org.alembic.aurion.common.nhinccommon.AssertionType;
import org.alembic.aurion.common.nhinccommon.NhinTargetSystemType;
import org.hl7.v3.PRPAIN201305UV02;
import org.hl7.v3.PRPAIN201306UV02;
/**
*
* @author jhoppesc
*/
public class NhinPatientDiscoveryNoOpImpl implements NhinPatientDiscoveryProxy {
public PRPAIN201306UV02 respondingGatewayPRPAIN201305UV02(PRPAIN201305UV02 request, AssertionType assertion, NhinTargetSystemType target) {
return new PRPAIN201306UV02();
}
}
|
[
"leswestberg@fake.com"
] |
leswestberg@fake.com
|
b3e382afddb7c4197c44e8d95053bc93511ede55
|
139960e2d7d55e71c15e6a63acb6609e142a2ace
|
/mobile_app1/module1022/src/main/java/module1022packageJava0/Foo163.java
|
5931cfff690611cc59fb0b6a4adf2dcee9d8d255
|
[
"Apache-2.0"
] |
permissive
|
uber-common/android-build-eval
|
448bfe141b6911ad8a99268378c75217d431766f
|
7723bfd0b9b1056892cef1fef02314b435b086f2
|
refs/heads/master
| 2023-02-18T22:25:15.121902
| 2023-02-06T19:35:34
| 2023-02-06T19:35:34
| 294,831,672
| 83
| 7
|
Apache-2.0
| 2021-09-24T08:55:30
| 2020-09-11T23:27:37
|
Java
|
UTF-8
|
Java
| false
| false
| 296
|
java
|
package module1022packageJava0;
import java.lang.Integer;
public class Foo163 {
Integer int0;
public void foo0() {
new module1022packageJava0.Foo162().foo3();
}
public void foo1() {
foo0();
}
public void foo2() {
foo1();
}
public void foo3() {
foo2();
}
}
|
[
"oliviern@uber.com"
] |
oliviern@uber.com
|
e1c4a27fbedd5311e1c0bd7b30cec65ab590abfb
|
094d929c094909378e5a6e3cba9962792addcc7c
|
/main/ip/src/boofcv/alg/interpolate/impl/ImplPolynomialPixel_F32.java
|
abe44e5ce59b781974c0e3e77a273e4498713a41
|
[
"Apache-2.0"
] |
permissive
|
marsPure/BoofCV
|
ca28345fcced383352929c47bbb5dd0f4f1d49f6
|
c4655b8cf296d12c4d16a3224d19bf5a640773c6
|
refs/heads/master
| 2020-04-06T06:51:40.998390
| 2015-06-06T17:17:07
| 2015-06-06T17:17:07
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,816
|
java
|
/*
* Copyright (c) 2011-2015, Peter Abeles. All Rights Reserved.
*
* This file is part of BoofCV (http://boofcv.org).
*
* 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 boofcv.alg.interpolate.impl;
import boofcv.alg.interpolate.PolynomialPixel;
import boofcv.core.image.border.ImageBorder_F32;
import boofcv.struct.image.ImageFloat32;
import boofcv.struct.image.ImageType;
/**
* <p>
* Implementation of {@link PolynomialPixel}.
* </p>
* <p>
* NOTE: This code was automatically generated using {@link GenerateImplPolynomialPixel}.
* </p>
*
* @author Peter Abeles
*/
public class ImplPolynomialPixel_F32 extends PolynomialPixel<ImageFloat32> {
public ImplPolynomialPixel_F32(int maxDegree, float min, float max) {
super(maxDegree, min, max);
}
@Override
public float get(float x, float y) {
if( x < 0 || y < 0 || x > image.width-1 || y > image.height-1 )
throw new IllegalArgumentException("Pixel out of bounds. "+x+" "+y);
int width = image.getWidth();
int height = image.getHeight();
final int xt = (int) x;
final int yt = (int) y;
// offM makes sure even numbered M will bound the test point with samples
int x0 = xt - M/2 + offM;
int x1 = x0 + M;
int y0 = yt - M/2 + offM;
int y1 = y0 + M;
if( x0 < 0 ) { x0 = 0;}
if( x1 > width) {x1 = width;}
if( y0 < 0 ) { y0 = 0;}
if( y1 > height) {y1 = height;}
final int horizM = x1-x0;
final int vertM = y1-y0;
interp1D.setInput(horiz,horizM);
for( int i = 0; i < vertM; i++ ) {
for( int j = 0; j < horizM; j++ ) {
horiz[j] = image.get(j+x0,i+y0);
}
vert[i]=interp1D.process(x-x0,0,horizM-1);
}
interp1D.setInput(vert,vertM);
float ret = interp1D.process(y-y0,0,vertM-1);
// because it is fitting polynomials it can go above and below max values.
if( ret > max ) {
ret = max;
} else if( ret < min ) {
ret = min;
}
return ret;
}
@Override
public float get_fast(float x, float y) {
int xt = (int) x;
int yt = (int) y;
int x0 = xt - M/2 + offM;
int y0 = yt - M/2 + offM;
interp1D.setInput(horiz,horiz.length);
for( int i = 0; i < M; i++ ) {
for( int j = 0; j < M; j++ ) {
horiz[j] = image.get(j+x0,i+y0);
}
vert[i]=interp1D.process(x-x0,0,M-1);
}
interp1D.setInput(vert,vert.length);
float ret = interp1D.process(y-y0,0,M-1);
// because it is fitting polynomials it can go above or below max or min values.
if( ret > max ) {
ret = max;
} else if( ret < min ) {
ret = min;
}
return ret;
}
@Override
public float get_border(float x, float y) {
int xt = (int) Math.floor(x);
int yt = (int) Math.floor(y);
int x0 = xt - M/2 + offM;
int y0 = yt - M/2 + offM;
ImageBorder_F32 border = (ImageBorder_F32)this.border;
interp1D.setInput(horiz,horiz.length);
for( int i = 0; i < M; i++ ) {
for( int j = 0; j < M; j++ ) {
horiz[j] = border.get(j+x0,i+y0);
}
vert[i]=interp1D.process(x-x0,0,M-1);
}
interp1D.setInput(vert,vert.length);
float ret = interp1D.process(y-y0,0,M-1);
// because it is fitting polynomials it can go above or below max or min values.
if( ret > max ) {
ret = max;
} else if( ret < min ) {
ret = min;
}
return ret;
}
@Override
public ImageType<ImageFloat32> getImageType() {
return ImageType.single(ImageFloat32.class);
}
}
|
[
"peter.abeles@gmail.com"
] |
peter.abeles@gmail.com
|
f38ba86029e7e109a406b2ebb3198ca347536557
|
7e96b71095545474bf4a3086710139012d7f28a8
|
/oauth2/src/main/java/com/oauth2/controller/OAuthController.java
|
0f6dfe2d0229775f084c4bb84d56293dbbf22d7a
|
[] |
no_license
|
BeomjunLee/SpringSecurity-OAuth2
|
e6805c3c4e579c564ce5016ed33c4965cebbe4e1
|
8dcc81058dc9f8a648e4b2670a2119e91f4ff4cf
|
refs/heads/main
| 2023-06-28T14:29:04.465597
| 2021-07-26T12:00:52
| 2021-07-26T12:00:52
| 334,474,029
| 3
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 706
|
java
|
package com.oauth2.controller;
import com.oauth2.annotation.LoginMember;
import com.oauth2.domain.SessionMember;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import javax.servlet.http.HttpSession;
@Controller
@RequiredArgsConstructor
public class OAuthController {
@GetMapping("/main")
public String index(Model model, @LoginMember SessionMember member) {
if(member != null) {
model.addAttribute("username", member.getName());
model.addAttribute("userImg", member.getPicture());
}
return "/main";
}
}
|
[
"qjawnswkd0717@gmail.com"
] |
qjawnswkd0717@gmail.com
|
82e7a30258cbbc676eb63c45c85180c449413176
|
fa91450deb625cda070e82d5c31770be5ca1dec6
|
/Diff-Raw-Data/10/10_23dde1601490e670e178495668230f4d2e8733b0/TeaserView/10_23dde1601490e670e178495668230f4d2e8733b0_TeaserView_t.java
|
c610ad11847f56fa19cef2d8f9119ec97532f837
|
[] |
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
| 4,846
|
java
|
package org.immopoly.android.widget;
import java.util.ArrayList;
import org.immopoly.android.R;
import org.immopoly.android.adapter.FlatsPagerAdapter;
import org.immopoly.android.constants.Const;
import org.immopoly.android.helper.Settings;
import org.immopoly.android.model.Flat;
import android.graphics.Point;
import android.graphics.drawable.ColorDrawable;
import android.support.v4.app.Fragment;
import android.util.Log;
import android.view.View;
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
import android.widget.FrameLayout;
import android.widget.RelativeLayout;
import com.google.android.maps.GeoPoint;
import com.google.android.maps.MapView;
public class TeaserView extends RelativeLayout {
// statics
private static float screenDesity = 1.0f; // like on a G1!!11!
private ArrayList<Flat> flats;
private MapView mapView;
public boolean animationDone; // TODO public
public GeoPoint mapIconGeoPoint; // TODO public
Point mapIconPos;
private ViewPager flatsPager;
private Fragment fragment;
private View noseView;
private boolean isPortfolio;
public TeaserView( Fragment fragment, MapView mapView, ArrayList<Flat> flats, boolean isPortfolio ) {
super( fragment.getActivity() );
this.isPortfolio = isPortfolio;
this.fragment = fragment;
this.mapView = mapView;
this.flats = flats;
screenDesity = Settings.getScreenDensity( fragment.getActivity() );
setBackgroundDrawable( new ColorDrawable( 0x00000000 ) );
int totalHeight = mapView.getHeight()/2;
int frameHeight = 122;
int noseHeight = totalHeight - (int) ((122 - 13)*screenDesity);
FrameLayout frame = new FrameLayout( fragment.getActivity() );
RelativeLayout.LayoutParams layoutParams = new RelativeLayout.LayoutParams(
(int) (330*screenDesity), (int) (frameHeight*screenDesity) );
layoutParams.alignWithParent = true;
layoutParams.addRule( RelativeLayout.CENTER_HORIZONTAL );
layoutParams.addRule( RelativeLayout.ALIGN_PARENT_TOP );
frame.setLayoutParams(layoutParams);
frame.setBackgroundResource(R.drawable.teaser_background);
frame.setId( 1 );
flatsPager = new ViewPager( fragment.getActivity() );
FlatsPagerAdapter pagerAdapter = new FlatsPagerAdapter( flats, fragment, isPortfolio );
flatsPager.setAdapter( pagerAdapter );
flatsPager.setPageMargin( (int) (3*screenDesity) );
if ( flats.size() > 1 )
flatsPager.setForcedChildWidth( (int) (260 * screenDesity) );
frame.addView( flatsPager );
addView( frame );
noseView = new View( fragment.getActivity() );
noseView.setBackgroundResource(R.drawable.teaser_nose);
layoutParams = new RelativeLayout.LayoutParams(
(int) (24*screenDesity), noseHeight );
layoutParams.addRule( RelativeLayout.CENTER_HORIZONTAL );
layoutParams.addRule( RelativeLayout.BELOW, frame.getId() );
layoutParams.setMargins(0, (int) (screenDesity*-13), 0, 0);
noseView.setLayoutParams(layoutParams);
addView( noseView );
setLayoutParams( new MapView.LayoutParams( (int)(330*screenDesity), totalHeight, mapView.getWidth()/2, 0, MapView.LayoutParams.TOP | MapView.LayoutParams.CENTER_HORIZONTAL | MapView.LayoutParams.MODE_VIEW ) );
mapView.addView( this );
Animation animation = AnimationUtils.loadAnimation( fragment.getActivity(), R.anim.bubble_animation );
animation.setAnimationListener( new Animation.AnimationListener() {
public void onAnimationStart(Animation animation) {}
public void onAnimationRepeat(Animation animation) {}
public void onAnimationEnd(Animation animation) {
animationDone = true;
}
} );
startAnimation( animation );
mapIconGeoPoint = new GeoPoint( (int) (flats.get(0).lat * 1E6), (int) (flats.get(0).lng * 1E6) );
mapIconPos = new Point( mapView.getWidth() / 2, mapView.getHeight() / 2 + ImmoscoutPlacesOverlay.markerBounds.height()*2/4 );
Point currentIconPos = mapView.getProjection().toPixels( mapIconGeoPoint, null );
int moveX = currentIconPos.x - mapView.getWidth()/2;
if ( flats.size() > 1 )
moveX -= (int) (3*screenDesity);
int moveY = currentIconPos.y - (mapView.getHeight() / 2 + ImmoscoutPlacesOverlay.markerBounds.height()*2/4);
Point moveToPoint = new Point( mapView.getWidth() / 2 + moveX, mapView.getHeight()/2 + moveY );
mapView.getController().animateTo( mapView.getProjection().fromPixels( moveToPoint.x, moveToPoint.y ) );
}
public void detach() {
this.mapView.removeView( this );
}
public void refreshContent() {
Log.i( Const.LOG_TAG, "TeaserBubble.refresh" );
int idx = flatsPager.getCurrentItem();
FlatsPagerAdapter pagerAdapter = new FlatsPagerAdapter( flats, fragment, isPortfolio );
flatsPager.setAdapter( pagerAdapter );
flatsPager.setCurrentItem( idx );
}
}
|
[
"yuzhongxing88@gmail.com"
] |
yuzhongxing88@gmail.com
|
370e568a3d4cbfcddb1d8ebc16e9a288b911de32
|
421f0a75a6b62c5af62f89595be61f406328113b
|
/generated_tests/no_seeding/83_xbus-net.sf.xbus.base.core.trace.FileTrace-1.0-9/net/sf/xbus/base/core/trace/FileTrace_ESTest_scaffolding.java
|
7e45dfeef6bc1ab72e86e3f921073f2fbca069a1
|
[] |
no_license
|
tigerqiu712/evosuite-model-seeding-empirical-evaluation
|
c78c4b775e5c074aaa5e6ca56bc394ec03c2c7c6
|
11a920b8213d9855082d3946233731c843baf7bc
|
refs/heads/master
| 2020-12-23T21:04:12.152289
| 2019-10-30T08:02:29
| 2019-10-30T08:02:29
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 543
|
java
|
/**
* Scaffolding file used to store all the setups needed to run
* tests automatically generated by EvoSuite
* Mon Oct 28 23:10:20 GMT 2019
*/
package net.sf.xbus.base.core.trace;
import org.evosuite.runtime.annotation.EvoSuiteClassExclude;
import org.junit.BeforeClass;
import org.junit.Before;
import org.junit.After;
import org.evosuite.runtime.sandbox.Sandbox;
import org.evosuite.runtime.sandbox.Sandbox.SandboxMode;
@EvoSuiteClassExclude
public class FileTrace_ESTest_scaffolding {
// Empty scaffolding for empty test suite
}
|
[
"pderakhshanfar@bsr01.win.tue.nl"
] |
pderakhshanfar@bsr01.win.tue.nl
|
343d3c4cba4f768161d0d04083b6e08c694e486c
|
30436ce0097ffbc25ec3fe731405121409bfe5e4
|
/bin/modules/common/src/main/java/com/beanframework/common/registry/AfterSaveListenerRegistry.java
|
543372bb393b53a43956917458d0e63b9c8c4d35
|
[
"MIT"
] |
permissive
|
williamtanws/beanframework
|
0ff351dc68dbc1a0fbf389c99de89ce35624f995
|
f89e6708f9e7deb79188cff7e306ae9487f9291c
|
refs/heads/master
| 2023-05-14T02:53:39.497987
| 2021-05-25T14:31:43
| 2021-05-25T14:31:43
| 150,228,256
| 1
| 0
|
MIT
| 2023-04-29T11:39:26
| 2018-09-25T07:59:25
|
JavaScript
|
UTF-8
|
Java
| false
| false
| 742
|
java
|
package com.beanframework.common.registry;
import java.util.Map;
import java.util.TreeMap;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
@Component
public class AfterSaveListenerRegistry {
protected static final Logger LOGGER = LoggerFactory.getLogger(AfterSaveListenerRegistry.class);
private Map<String, AfterSaveListener> listeners = new TreeMap<String, AfterSaveListener>();
public Map<String, AfterSaveListener> getListeners() {
return listeners;
}
public void addListener(AfterSaveListener listener) {
listeners.put(listener.getClass().getName(), listener);
}
public void removeListener(String className) {
listeners.remove(className);
}
}
|
[
"william.tan@bertelsmann.de"
] |
william.tan@bertelsmann.de
|
858360e71b922f1b020ce522d37587b65f1f647e
|
5e3235edf3de262f4d10b9e9e1fcc3bd13d6b8b1
|
/Code Snippet Repository/Spring/Spring11324.java
|
dad2891dfdfb0a10e12f4696b5bbc472704263e9
|
[] |
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
| 526
|
java
|
private void updateBindingContext(BindingContext context, ServerWebExchange exchange) {
Map<String, Object> model = context.getModel().asMap();
model.keySet().stream()
.filter(name -> isBindingCandidate(name, model.get(name)))
.filter(name -> !model.containsKey(BindingResult.MODEL_KEY_PREFIX + name))
.forEach(name -> {
WebExchangeDataBinder binder = context.createDataBinder(exchange, model.get(name), name);
model.put(BindingResult.MODEL_KEY_PREFIX + name, binder.getBindingResult());
});
}
|
[
"Qing.Mi@my.cityu.edu.hk"
] |
Qing.Mi@my.cityu.edu.hk
|
7e4b23a7fbcb298e9e442a743493d5c290a9d15d
|
fd49852c3426acf214b390c33927b5a30aeb0e0a
|
/aosp/javalib/android/hardware/face/FaceManager$2.java
|
21b0dbe7ec53afbdf5e38f8d9ad1ea37d461c31c
|
[] |
no_license
|
HanChangHun/MobilePlus-Prototype
|
fb72a49d4caa04bce6edb4bc060123c238a6a94e
|
3047c44a0a2859bf597870b9bf295cf321358de7
|
refs/heads/main
| 2023-06-10T19:51:23.186241
| 2021-06-26T08:28:58
| 2021-06-26T08:28:58
| 333,411,414
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,220
|
java
|
package android.hardware.face;
import android.hardware.biometrics.IBiometricServiceLockoutResetCallback;
import android.os.Handler;
import android.os.IRemoteCallback;
import android.os.PowerManager;
import android.os.RemoteException;
class null extends IBiometricServiceLockoutResetCallback.Stub {
public void onLockoutReset(long paramLong, IRemoteCallback paramIRemoteCallback) throws RemoteException {
try {
PowerManager.WakeLock wakeLock = powerManager.newWakeLock(1, "faceLockoutResetCallback");
wakeLock.acquire();
Handler handler = FaceManager.access$000(FaceManager.this);
FaceManager.LockoutResetCallback lockoutResetCallback = callback;
_$$Lambda$FaceManager$2$IVmrd2VOH7JdDdb7PFFlL5bjZ5w _$$Lambda$FaceManager$2$IVmrd2VOH7JdDdb7PFFlL5bjZ5w = new _$$Lambda$FaceManager$2$IVmrd2VOH7JdDdb7PFFlL5bjZ5w();
this(lockoutResetCallback, wakeLock);
handler.post(_$$Lambda$FaceManager$2$IVmrd2VOH7JdDdb7PFFlL5bjZ5w);
return;
} finally {
paramIRemoteCallback.sendResult(null);
}
}
}
/* Location: /home/chun/Desktop/temp/!/android/hardware/face/FaceManager$2.class
* Java compiler version: 8 (52.0)
* JD-Core Version: 1.1.3
*/
|
[
"ehwjs1914@naver.com"
] |
ehwjs1914@naver.com
|
b4a74ab1e8e164596fb4bcea0bea4c78c090ce62
|
b332635216e1b4fe59e371a712a1e6348a3bdb67
|
/google-api-grpc/proto-google-cloud-vision-v1p4beta1/src/main/java/com/google/cloud/vision/v1p4beta1/WebDetectionProto.java
|
2856fb27ba87de55a50a6949dce683dbcdf4c1e8
|
[
"LicenseRef-scancode-unknown-license-reference",
"Apache-2.0"
] |
permissive
|
bolcom/google-cloud-java
|
81b6eb3ed7f971087d84c58e8adefaa5cbc13e12
|
adf0d35194c48f160c243d4b52ad40016d1c44c6
|
refs/heads/master
| 2021-03-08T16:00:37.972415
| 2019-09-09T14:38:43
| 2019-11-07T10:48:27
| 207,309,661
| 1
| 1
|
Apache-2.0
| 2019-09-09T12:59:19
| 2019-09-09T12:59:19
| null |
UTF-8
|
Java
| false
| true
| 8,052
|
java
|
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/cloud/vision/v1p4beta1/web_detection.proto
package com.google.cloud.vision.v1p4beta1;
public final class WebDetectionProto {
private WebDetectionProto() {}
public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {}
public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry);
}
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_vision_v1p4beta1_WebDetection_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_vision_v1p4beta1_WebDetection_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebEntity_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebEntity_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebImage_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebImage_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebLabel_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebLabel_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebPage_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebPage_fieldAccessorTable;
public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
return descriptor;
}
private static com.google.protobuf.Descriptors.FileDescriptor descriptor;
static {
java.lang.String[] descriptorData = {
"\n1google/cloud/vision/v1p4beta1/web_dete"
+ "ction.proto\022\035google.cloud.vision.v1p4bet"
+ "a1\032\034google/api/annotations.proto\"\214\007\n\014Web"
+ "Detection\022K\n\014web_entities\030\001 \003(\01325.google"
+ ".cloud.vision.v1p4beta1.WebDetection.Web"
+ "Entity\022R\n\024full_matching_images\030\002 \003(\01324.g"
+ "oogle.cloud.vision.v1p4beta1.WebDetectio"
+ "n.WebImage\022U\n\027partial_matching_images\030\003 "
+ "\003(\01324.google.cloud.vision.v1p4beta1.WebD"
+ "etection.WebImage\022W\n\032pages_with_matching"
+ "_images\030\004 \003(\01323.google.cloud.vision.v1p4"
+ "beta1.WebDetection.WebPage\022U\n\027visually_s"
+ "imilar_images\030\006 \003(\01324.google.cloud.visio"
+ "n.v1p4beta1.WebDetection.WebImage\022O\n\021bes"
+ "t_guess_labels\030\010 \003(\01324.google.cloud.visi"
+ "on.v1p4beta1.WebDetection.WebLabel\032B\n\tWe"
+ "bEntity\022\021\n\tentity_id\030\001 \001(\t\022\r\n\005score\030\002 \001("
+ "\002\022\023\n\013description\030\003 \001(\t\032&\n\010WebImage\022\013\n\003ur"
+ "l\030\001 \001(\t\022\r\n\005score\030\002 \001(\002\0320\n\010WebLabel\022\r\n\005la"
+ "bel\030\001 \001(\t\022\025\n\rlanguage_code\030\002 \001(\t\032\344\001\n\007Web"
+ "Page\022\013\n\003url\030\001 \001(\t\022\r\n\005score\030\002 \001(\002\022\022\n\npage"
+ "_title\030\003 \001(\t\022R\n\024full_matching_images\030\004 \003"
+ "(\01324.google.cloud.vision.v1p4beta1.WebDe"
+ "tection.WebImage\022U\n\027partial_matching_ima"
+ "ges\030\005 \003(\01324.google.cloud.vision.v1p4beta"
+ "1.WebDetection.WebImageB\207\001\n!com.google.c"
+ "loud.vision.v1p4beta1B\021WebDetectionProto"
+ "P\001ZCgoogle.golang.org/genproto/googleapi"
+ "s/cloud/vision/v1p4beta1;vision\370\001\001\242\002\004GCV"
+ "Nb\006proto3"
};
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
public com.google.protobuf.ExtensionRegistry assignDescriptors(
com.google.protobuf.Descriptors.FileDescriptor root) {
descriptor = root;
return null;
}
};
com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
descriptorData,
new com.google.protobuf.Descriptors.FileDescriptor[] {
com.google.api.AnnotationsProto.getDescriptor(),
},
assigner);
internal_static_google_cloud_vision_v1p4beta1_WebDetection_descriptor =
getDescriptor().getMessageTypes().get(0);
internal_static_google_cloud_vision_v1p4beta1_WebDetection_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_vision_v1p4beta1_WebDetection_descriptor,
new java.lang.String[] {
"WebEntities",
"FullMatchingImages",
"PartialMatchingImages",
"PagesWithMatchingImages",
"VisuallySimilarImages",
"BestGuessLabels",
});
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebEntity_descriptor =
internal_static_google_cloud_vision_v1p4beta1_WebDetection_descriptor
.getNestedTypes()
.get(0);
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebEntity_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebEntity_descriptor,
new java.lang.String[] {
"EntityId", "Score", "Description",
});
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebImage_descriptor =
internal_static_google_cloud_vision_v1p4beta1_WebDetection_descriptor
.getNestedTypes()
.get(1);
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebImage_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebImage_descriptor,
new java.lang.String[] {
"Url", "Score",
});
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebLabel_descriptor =
internal_static_google_cloud_vision_v1p4beta1_WebDetection_descriptor
.getNestedTypes()
.get(2);
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebLabel_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebLabel_descriptor,
new java.lang.String[] {
"Label", "LanguageCode",
});
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebPage_descriptor =
internal_static_google_cloud_vision_v1p4beta1_WebDetection_descriptor
.getNestedTypes()
.get(3);
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebPage_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_vision_v1p4beta1_WebDetection_WebPage_descriptor,
new java.lang.String[] {
"Url", "Score", "PageTitle", "FullMatchingImages", "PartialMatchingImages",
});
com.google.api.AnnotationsProto.getDescriptor();
}
// @@protoc_insertion_point(outer_class_scope)
}
|
[
"45548808+kolea2@users.noreply.github.com"
] |
45548808+kolea2@users.noreply.github.com
|
186c1e1dd2aab366f4bf751844330ecb1a8e99ee
|
187efeb37a1db9d4b0dd04c7d5795123ecb86a36
|
/src/main/java/com/gdtopway/module/auth/web/UserController.java
|
963073d9f72d475275b5735f9f42c202da40620e
|
[
"Apache-2.0"
] |
permissive
|
travelersun/gdtopway-core
|
92bf7c08a0f82659feed8e7f424847bbadaef754
|
7e31d6e3215e6a62fe269fff85a9885d7091fcbd
|
refs/heads/master
| 2021-01-20T14:17:10.261925
| 2018-01-21T16:44:19
| 2018-01-21T16:44:19
| 90,585,069
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 8,450
|
java
|
package com.gdtopway.module.auth.web;
import java.util.List;
import java.util.Map;
import java.util.Set;
import javax.servlet.http.HttpServletRequest;
import org.apache.commons.lang3.StringUtils;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.apache.shiro.authz.annotation.RequiresUser;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
import com.gdtopway.core.annotation.MenuData;
import com.gdtopway.core.annotation.MetaData;
import com.gdtopway.core.pagination.GroupPropertyFilter;
import com.gdtopway.core.pagination.PropertyFilter;
import com.gdtopway.core.pagination.PropertyFilter.MatchType;
import com.gdtopway.core.security.AuthUserDetails;
import com.gdtopway.core.service.BaseService;
import com.gdtopway.core.service.Validation;
import com.gdtopway.core.util.EnumUtils;
import com.gdtopway.core.web.BaseController;
import com.gdtopway.core.web.view.OperationResult;
import com.gdtopway.module.auth.entity.Privilege;
import com.gdtopway.module.auth.entity.RoleR2Privilege;
import com.gdtopway.module.auth.entity.User;
import com.gdtopway.module.auth.entity.UserR2Role;
import com.gdtopway.module.auth.entity.User.AuthTypeEnum;
import com.gdtopway.module.auth.service.PrivilegeService;
import com.gdtopway.module.auth.service.RoleService;
import com.gdtopway.module.auth.service.UserService;
import com.gdtopway.module.sys.service.MenuService;
import com.gdtopway.module.sys.vo.NavMenuVO;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import com.google.common.collect.Sets;
@Controller
@RequestMapping(value = "/admin/auth/user")
public class UserController extends BaseController<User, Long> {
@Autowired
private UserService userService;
@Autowired
private RoleService roleService;
@Autowired
private PrivilegeService privilegeService;
@Autowired
private MenuService menuService;
@Override
protected BaseService<User, Long> getEntityService() {
return userService;
}
@RequiresUser
@ModelAttribute
public void prepareModel(HttpServletRequest request, Model model, @RequestParam(value = "id", required = false) Long id) {
super.initPrepareModel(request, model, id);
}
@MenuData("配置管理:权限管理:用户账号")
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "", method = RequestMethod.GET)
public String index(Model model) {
model.addAttribute("authTypeMap", EnumUtils.getEnumDataMap(AuthTypeEnum.class));
return "admin/auth/user-index";
}
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "/list", method = RequestMethod.GET)
@ResponseBody
public Page<User> findByPage(HttpServletRequest request) {
return super.findByPage(User.class, request);
}
@RequestMapping(value = "/edit-tabs", method = RequestMethod.GET)
public String editTabs(HttpServletRequest request) {
return "admin/auth/user-inputTabs";
}
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "/edit", method = RequestMethod.GET)
public String editShow(Model model, @ModelAttribute("entity") User entity) {
model.addAttribute("authTypeMap", EnumUtils.getEnumDataMap(AuthTypeEnum.class));
model.addAttribute("roles", roleService.findAllCached());
if (entity.isNew()) {
entity.setMgmtGranted(true);
}
return "admin/auth/user-inputBasic";
}
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "/edit", method = RequestMethod.POST)
@ResponseBody
public OperationResult editSave(@ModelAttribute("entity") User entity, Model model,
@RequestParam(value = "rawPassword", required = false) String rawPassword) {
Validation.notDemoMode();
if (entity.isNew()) {
Validation.isTrue(StringUtils.isNotBlank(rawPassword), "创建用户必须设置初始密码");
}
userService.saveCascadeR2Roles(entity, rawPassword);
return OperationResult.buildSuccessResult("数据保存处理完成", entity);
}
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "/delete", method = RequestMethod.POST)
@ResponseBody
public OperationResult delete(@RequestParam("ids") Long... ids) {
Validation.notDemoMode();
return super.delete(ids);
}
@MetaData(value = "汇总用户关联权限集合")
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "/privileges", method = RequestMethod.GET)
public String privileges(Model model, @ModelAttribute("entity") User entity) {
Set<Long> r2PrivilegeIds = Sets.newHashSet();
List<Privilege> privileges = privilegeService.findAllCached();
List<UserR2Role> userR2Roles = entity.getUserR2Roles() == null ? Lists.newArrayList() : entity.getUserR2Roles();
boolean isAdmin = false;
for (UserR2Role r2 : userR2Roles) {
if (r2.getRole().getCode().equals(AuthUserDetails.ROLE_SUPER_USER)) {
isAdmin = true;
break;
}
}
if (isAdmin) {
for (Privilege privilege : privileges) {
r2PrivilegeIds.add(privilege.getId());
}
} else {
for (UserR2Role userR2Role : userR2Roles) {
List<RoleR2Privilege> roleR2Privileges = userR2Role.getRole().getRoleR2Privileges();
for (RoleR2Privilege roleR2Privilege : roleR2Privileges) {
r2PrivilegeIds.add(roleR2Privilege.getPrivilege().getId());
}
}
}
model.addAttribute("r2PrivilegeIds", StringUtils.join(r2PrivilegeIds, ","));
return "admin/auth/user-privileges";
}
@MetaData(value = "汇总用户关联菜单集合")
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "/menus", method = RequestMethod.GET)
public String menusShow(Model model) {
return "admin/auth/user-menus";
}
@RequiresPermissions("配置管理:权限管理:用户账号")
@RequestMapping(value = "/menus/data", method = RequestMethod.GET)
@ResponseBody
public Object menusData(Model model, @ModelAttribute("entity") User entity) {
List<Map<String, Object>> items = Lists.newArrayList();
List<NavMenuVO> navMenuVOs = menuService.processUserMenu(entity);
for (NavMenuVO navMenuVO : navMenuVOs) {
//组装zTree结构数据
Map<String, Object> item = Maps.newHashMap();
item.put("id", navMenuVO.getId());
item.put("pId", navMenuVO.getParentId());
item.put("name", navMenuVO.getName());
item.put("open", true);
item.put("isParent", StringUtils.isBlank(navMenuVO.getUrl()));
items.add(item);
}
return items;
}
@RequestMapping(value = "/tags", method = RequestMethod.GET)
@ResponseBody
public List<Map<String, Object>> tagsData(Model model, @RequestParam("q") String q) {
GroupPropertyFilter groupFilter = GroupPropertyFilter.buildDefaultOrGroupFilter();
groupFilter.append(new PropertyFilter(MatchType.CN, "authUid", q));
groupFilter.append(new PropertyFilter(MatchType.CN, "nickName", q));
groupFilter.append(new PropertyFilter(MatchType.CN, "email", q));
groupFilter.append(new PropertyFilter(MatchType.CN, "mobile", q));
List<User> users = userService.findByFilters(groupFilter);
List<Map<String, Object>> items = Lists.newArrayList();
for (User user : users) {
Map<String, Object> item = Maps.newHashMap();
item.put("id", user.getAlias());
item.put("text", user.getAlias());
items.add(item);
}
return items;
}
}
|
[
"2812849244@qq.com"
] |
2812849244@qq.com
|
f59db63304a7958b2c56d46cbd87ac964435c7cb
|
be73270af6be0a811bca4f1710dc6a038e4a8fd2
|
/crash-reproduction-moho/results/XWIKI-14475-3-5-SPEA2-WeightedSum:TestLen:CallDiversity/org/xwiki/platform/wiki/creationjob/internal/WikiCreationJob_ESTest.java
|
4a584778d12dbc563a20202d4f98a224d266f123
|
[] |
no_license
|
STAMP-project/Botsing-multi-objectivization-using-helper-objectives-application
|
cf118b23ecb87a8bf59643e42f7556b521d1f754
|
3bb39683f9c343b8ec94890a00b8f260d158dfe3
|
refs/heads/master
| 2022-07-29T14:44:00.774547
| 2020-08-10T15:14:49
| 2020-08-10T15:14:49
| 285,804,495
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 581
|
java
|
/*
* This file was automatically generated by EvoSuite
* Sat Jan 18 23:10:55 UTC 2020
*/
package org.xwiki.platform.wiki.creationjob.internal;
import org.junit.Test;
import static org.junit.Assert.*;
import org.evosuite.runtime.EvoRunner;
import org.evosuite.runtime.EvoRunnerParameters;
import org.junit.runner.RunWith;
@RunWith(EvoRunner.class) @EvoRunnerParameters(useVFS = true, useJEE = true)
public class WikiCreationJob_ESTest extends WikiCreationJob_ESTest_scaffolding {
@Test
public void notGeneratedAnyTest() {
// EvoSuite did not generate any tests
}
}
|
[
"pouria.derakhshanfar@gmail.com"
] |
pouria.derakhshanfar@gmail.com
|
201c726c9ed0562b94c028bb0da1a960bcff621b
|
a49a32409cc716ea547f0e3181e7b9625bfae86f
|
/src/main/java/com/rmbank/supervision/model/FunctionResourceVM.java
|
9296c9aee2ac30d6202b1dd21435abbfb96433fb
|
[] |
no_license
|
supervision-dev/supervision-manager
|
7b6728fbd6feac111f4c9dcecc71e09eed797f89
|
e289d0edb1b36dfb58517b2dfbecd4f39af35669
|
refs/heads/master
| 2021-01-21T14:32:18.367738
| 2018-10-28T12:31:48
| 2018-10-28T12:31:48
| 95,291,594
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 804
|
java
|
package com.rmbank.supervision.model;
import java.util.List;
public class FunctionResourceVM {
private Integer id;//所属模块Id;
private String name;//所属模块名称;
private List<ResourceConfig> itemList;
private List<Permission> permissionList;
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public List<ResourceConfig> getItemList() {
return itemList;
}
public void setItemList(List<ResourceConfig> itemList) {
this.itemList = itemList;
}
public List<Permission> getPermissionList() {
return permissionList;
}
public void setPermissionList(List<Permission> permissionList) {
this.permissionList = permissionList;
}
}
|
[
"xiaohutuxian5212@163.com"
] |
xiaohutuxian5212@163.com
|
ce0c5eb1cd83ce7466feeade6d77825de9231000
|
7798c2c1f62c76c0de846ffd6f87eb704f4ebb40
|
/src/test/java/devs/team/net/service/UserServiceIntTest.java
|
dc7562dd13f92953edbcec610890d7f750d4623b
|
[] |
no_license
|
BulkSecurityGeneratorProject/SystemAguaPotable
|
f077a0dee18c1b0ee7fe29195186e91f3f56d837
|
d45ccb7e9b9d25a51b3b00e04eeccb9fe1fb141c
|
refs/heads/master
| 2022-12-18T10:51:51.173691
| 2018-04-01T15:36:21
| 2018-04-01T15:36:21
| 296,568,207
| 0
| 0
| null | 2020-09-18T08:56:36
| 2020-09-18T08:56:35
| null |
UTF-8
|
Java
| false
| false
| 6,365
|
java
|
package devs.team.net.service;
import devs.team.net.SystemAguaPotableApp;
import devs.team.net.config.Constants;
import devs.team.net.domain.User;
import devs.team.net.repository.UserRepository;
import devs.team.net.service.dto.UserDTO;
import devs.team.net.service.util.RandomUtil;
import org.apache.commons.lang3.RandomStringUtils;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;
import org.springframework.test.context.junit4.SpringRunner;
import org.springframework.transaction.annotation.Transactional;
import java.time.Instant;
import java.time.temporal.ChronoUnit;
import java.util.List;
import java.util.Optional;
import static org.assertj.core.api.Assertions.assertThat;
/**
* Test class for the UserResource REST controller.
*
* @see UserService
*/
@RunWith(SpringRunner.class)
@SpringBootTest(classes = SystemAguaPotableApp.class)
@Transactional
public class UserServiceIntTest {
@Autowired
private UserRepository userRepository;
@Autowired
private UserService userService;
private User user;
@Before
public void init() {
user = new User();
user.setLogin("johndoe");
user.setPassword(RandomStringUtils.random(60));
user.setActivated(true);
user.setEmail("johndoe@localhost");
user.setFirstName("john");
user.setLastName("doe");
user.setImageUrl("http://placehold.it/50x50");
user.setLangKey("en");
}
@Test
@Transactional
public void assertThatUserMustExistToResetPassword() {
userRepository.saveAndFlush(user);
Optional<User> maybeUser = userService.requestPasswordReset("invalid.login@localhost");
assertThat(maybeUser).isNotPresent();
maybeUser = userService.requestPasswordReset(user.getEmail());
assertThat(maybeUser).isPresent();
assertThat(maybeUser.orElse(null).getEmail()).isEqualTo(user.getEmail());
assertThat(maybeUser.orElse(null).getResetDate()).isNotNull();
assertThat(maybeUser.orElse(null).getResetKey()).isNotNull();
}
@Test
@Transactional
public void assertThatOnlyActivatedUserCanRequestPasswordReset() {
user.setActivated(false);
userRepository.saveAndFlush(user);
Optional<User> maybeUser = userService.requestPasswordReset(user.getLogin());
assertThat(maybeUser).isNotPresent();
userRepository.delete(user);
}
@Test
@Transactional
public void assertThatResetKeyMustNotBeOlderThan24Hours() {
Instant daysAgo = Instant.now().minus(25, ChronoUnit.HOURS);
String resetKey = RandomUtil.generateResetKey();
user.setActivated(true);
user.setResetDate(daysAgo);
user.setResetKey(resetKey);
userRepository.saveAndFlush(user);
Optional<User> maybeUser = userService.completePasswordReset("johndoe2", user.getResetKey());
assertThat(maybeUser).isNotPresent();
userRepository.delete(user);
}
@Test
@Transactional
public void assertThatResetKeyMustBeValid() {
Instant daysAgo = Instant.now().minus(25, ChronoUnit.HOURS);
user.setActivated(true);
user.setResetDate(daysAgo);
user.setResetKey("1234");
userRepository.saveAndFlush(user);
Optional<User> maybeUser = userService.completePasswordReset("johndoe2", user.getResetKey());
assertThat(maybeUser).isNotPresent();
userRepository.delete(user);
}
@Test
@Transactional
public void assertThatUserCanResetPassword() {
String oldPassword = user.getPassword();
Instant daysAgo = Instant.now().minus(2, ChronoUnit.HOURS);
String resetKey = RandomUtil.generateResetKey();
user.setActivated(true);
user.setResetDate(daysAgo);
user.setResetKey(resetKey);
userRepository.saveAndFlush(user);
Optional<User> maybeUser = userService.completePasswordReset("johndoe2", user.getResetKey());
assertThat(maybeUser).isPresent();
assertThat(maybeUser.orElse(null).getResetDate()).isNull();
assertThat(maybeUser.orElse(null).getResetKey()).isNull();
assertThat(maybeUser.orElse(null).getPassword()).isNotEqualTo(oldPassword);
userRepository.delete(user);
}
@Test
@Transactional
public void testFindNotActivatedUsersByCreationDateBefore() {
Instant now = Instant.now();
user.setActivated(false);
User dbUser = userRepository.saveAndFlush(user);
dbUser.setCreatedDate(now.minus(4, ChronoUnit.DAYS));
userRepository.saveAndFlush(user);
List<User> users = userRepository.findAllByActivatedIsFalseAndCreatedDateBefore(now.minus(3, ChronoUnit.DAYS));
assertThat(users).isNotEmpty();
userService.removeNotActivatedUsers();
users = userRepository.findAllByActivatedIsFalseAndCreatedDateBefore(now.minus(3, ChronoUnit.DAYS));
assertThat(users).isEmpty();
}
@Test
@Transactional
public void assertThatAnonymousUserIsNotGet() {
user.setLogin(Constants.ANONYMOUS_USER);
if (!userRepository.findOneByLogin(Constants.ANONYMOUS_USER).isPresent()) {
userRepository.saveAndFlush(user);
}
final PageRequest pageable = new PageRequest(0, (int) userRepository.count());
final Page<UserDTO> allManagedUsers = userService.getAllManagedUsers(pageable);
assertThat(allManagedUsers.getContent().stream()
.noneMatch(user -> Constants.ANONYMOUS_USER.equals(user.getLogin())))
.isTrue();
}
@Test
@Transactional
public void testRemoveNotActivatedUsers() {
user.setActivated(false);
userRepository.saveAndFlush(user);
// Let the audit first set the creation date but then update it
user.setCreatedDate(Instant.now().minus(30, ChronoUnit.DAYS));
userRepository.saveAndFlush(user);
assertThat(userRepository.findOneByLogin("johndoe")).isPresent();
userService.removeNotActivatedUsers();
assertThat(userRepository.findOneByLogin("johndoe")).isNotPresent();
}
}
|
[
"jhipster-bot@users.noreply.github.com"
] |
jhipster-bot@users.noreply.github.com
|
b922d40f5684fc2b0d131b1358b6a7b5f1f90f77
|
1629e37bba65c44f8cf5e88d73c71870089041a4
|
/JAVA高级/day61_lucene02/IKAnalyzer/IKAnalyzer3.2.0Stable_src/org/wltea/analyzer/dic/Hit.java
|
8812b6f4422c228c9635f6f6563f5d139606ef79
|
[] |
no_license
|
15529343201/Java-Web
|
e202e242663911420879685c6762c8d232ef5d61
|
15886604aa7b732d42f7f5783f73766da34923e2
|
refs/heads/master
| 2021-01-19T08:50:32.816256
| 2019-03-28T23:34:31
| 2019-03-28T23:34:31
| 87,683,430
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,204
|
java
|
/**
*
*/
package org.wltea.analyzer.dic;
/**
* IK Analyzer v3.2
* 表示词典检索的命中结果
* @author 林良益
*
*/
public class Hit {
//Hit不匹配
private static final int UNMATCH = 0x00000000;
//Hit完全匹配
private static final int MATCH = 0x00000001;
//Hit前缀匹配
private static final int PREFIX = 0x00000010;
//该HIT当前状态,默认未匹配
private int hitState = UNMATCH;
/**
* 判断是否完全匹配
*/
public boolean isMatch() {
return (this.hitState & MATCH) > 0;
}
/**
*
*/
public void setMatch() {
this.hitState = this.hitState | MATCH;
}
// /**
// * 判断是否完全匹配,且是另一个词的前缀
// */
// public boolean isMatchAndPrefix() {
// return ((this.hitState & MATCH) > 0) && ((this.hitState & PREFIX) > 0);
// }
/**
* 判断是否是词的前缀
*/
public boolean isPrefix() {
return (this.hitState & PREFIX) > 0;
}
/**
*
*/
public void setPrefix() {
this.hitState = this.hitState | PREFIX;
}
/**
* 判断是否是不匹配
*/
public boolean isUnmatch() {
return this.hitState == UNMATCH ;
}
/**
*
*/
public void setUnmatch() {
this.hitState = UNMATCH;
}
}
|
[
"15529343201@139.com"
] |
15529343201@139.com
|
4da18fc2627f9e8bd47e5de7b349ce525ee4aa92
|
da1aabfd2ea27438669b2e5be674932e2499a65c
|
/src/main/java/com/lab/labbook/controller/LabBookController.java
|
e23fc5548a89ed8c7e74ccda90247472fa987dc2
|
[] |
no_license
|
binkul/Rest-labbook
|
daf0ebba2679ac1954ab18b843cb0a715d9af90e
|
6ea2243d2780da48da057976bca5abd14ac3c8da
|
refs/heads/master
| 2022-11-10T22:30:55.046334
| 2020-07-02T17:29:50
| 2020-07-02T17:29:50
| 266,193,411
| 0
| 0
| null | 2020-07-02T17:29:51
| 2020-05-22T19:38:28
|
Java
|
UTF-8
|
Java
| false
| false
| 1,673
|
java
|
package com.lab.labbook.controller;
import com.lab.labbook.entity.dto.LabBookDto;
import com.lab.labbook.entity.extended.LabBookExtDto;
import com.lab.labbook.service.LabBookService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;
import java.util.List;
import java.util.Map;
@RequiredArgsConstructor
@RestController
@RequestMapping("/v1/lab")
public class LabBookController {
private final LabBookService service;
@GetMapping(value = "/all")
public List<LabBookExtDto> getAll() {
return service.getAll();
}
@GetMapping
public List<LabBookExtDto> getByTitle(@RequestParam("title") String title) {
return service.getByTitle(title);
}
@GetMapping(value = "/user/{userId}/title")
public List<LabBookExtDto> getByUserAndTitle(@PathVariable Long userId, @RequestParam String title) {
return service.getByUserAndTitle(userId, title);
}
@GetMapping(value = "/user/{userId}")
public List<LabBookExtDto> getByUser(@PathVariable Long userId) {
return service.getByUser(userId);
}
@GetMapping(value = "/{id}")
public LabBookExtDto getById(@PathVariable Long id) {
return service.getById(id);
}
@PostMapping
public void create(@RequestBody LabBookDto labBookDto) {
service.create(labBookDto);
}
@PatchMapping(value = "/{labId}")
public LabBookExtDto update(@RequestBody Map<String, String> updates, @PathVariable Long labId) {
return service.update(updates, labId);
}
@DeleteMapping(value = "/{id}")
public void delete(@PathVariable Long id) {
service.delete(id);
}
}
|
[
"jacekbinkul@gmail.com"
] |
jacekbinkul@gmail.com
|
1aeb7aef3ed2894b245073898d53e96a01b386c5
|
ba48e5dc43badfa82a423a6dc4c6957faa0ceff0
|
/module_user_store/src/main/java/com/xingshi/local_shop/adapter/LocalSellerAdapter.java
|
258f9319b3011474f0cad34c83183894e2eb3047
|
[] |
no_license
|
sengeiou/wangyihai
|
048d6a880297c6605bde0bbc26857ef60463b3ac
|
5b21bb6b04015bfb2811b843a417d9b22fe836cb
|
refs/heads/master
| 2022-07-19T11:49:37.255494
| 2020-05-23T10:42:43
| 2020-05-23T10:42:43
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,276
|
java
|
package com.xingshi.local_shop.adapter;
import android.content.Context;
import android.support.v7.widget.GridLayoutManager;
import android.support.v7.widget.RecyclerView;
import com.xingshi.adapter.MyRecyclerAdapter;
import com.xingshi.adapter.RecyclerViewHolder;
import com.xingshi.bean.LocalShopBean;
import com.xingshi.user_store.R;
import com.xingshi.utils.ArithUtil;
import com.xingshi.utils.SpaceItemDecoration;
import com.xingshi.view.RatingBarView;
import java.util.List;
public class LocalSellerAdapter extends MyRecyclerAdapter<LocalShopBean> {
public LocalSellerAdapter(Context context, List<LocalShopBean> mList, int mLayoutId) {
super(context, mList, mLayoutId);
}
@Override
public void convert(RecyclerViewHolder holder, LocalShopBean data, int position) {
holder.setImageUrl(R.id.rv_local_seller_img, data.getSeller_logo())
.setText(R.id.rv_local_seller_name, data.getSeller_shop_name())
.setText(R.id.rv_local_seller_type, data.getSeller_category_name())
.setText(R.id.rv_local_seller_address, data.getSeller_addredd());
RatingBarView star = holder.getView(R.id.rv_local_seller_star);
star.setClickable(false);
star.setStar(Integer.valueOf(data.getStar()), false);
if (data.getDistance() != null) {
Integer integer = Integer.valueOf(data.getDistance().split("\\.")[0]);
if (integer >= 1000) {
holder.setText(R.id.rv_local_seller_distance, ArithUtil.div(integer * 1.0, 1000.0, 1) + "千米");
} else {
holder.setText(R.id.rv_local_seller_distance, integer + "米");
}
}
RecyclerView rv = holder.getView(R.id.rv_local_seller_rv);
GridLayoutManager layoutManager = new GridLayoutManager(context, 3);
rv.setLayoutManager(layoutManager);
if (rv.getItemDecorationCount() == 0) {
rv.addItemDecoration(new SpaceItemDecoration(0, (int) context.getResources().getDimension(R.dimen.dp_10), 0, (int) context.getResources().getDimension(R.dimen.dp_10)));
}
ManJianAdapter adapter = new ManJianAdapter(context, data.getCouponList(), R.layout.rv_local_seller_inside);
rv.setAdapter(adapter);
}
}
|
[
"ellliot_zhang_z@163.com"
] |
ellliot_zhang_z@163.com
|
93ebe05f9c7a35ac249f938a04cfb399255aae31
|
d5decb236da7da2bb8d123311207766b6a8435cf
|
/src/com/taobao/api/response/PromotionLimitdiscountDetailGetResponse.java
|
d980ffff56bcc16e1cb3f4b819bf1df812b10964
|
[] |
no_license
|
tasfe/my-project-taobao-demo
|
85fee9861361e1e9ef4810f56aa5bbb3290ea216
|
f05a8141b6f3b23e88053bad4a12c8a138c2ef51
|
refs/heads/master
| 2021-01-13T01:30:17.440485
| 2013-02-16T08:38:02
| 2013-02-16T08:38:02
| 32,249,939
| 0
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,007
|
java
|
package com.taobao.api.response;
import java.util.List;
import com.taobao.api.internal.mapping.ApiField;
import com.taobao.api.internal.mapping.ApiListField;
import com.taobao.api.domain.LimitDiscountDetail;
import com.taobao.api.TaobaoResponse;
/**
* TOP API: taobao.promotion.limitdiscount.detail.get response.
*
* @author auto create
* @since 1.0, null
*/
public class PromotionLimitdiscountDetailGetResponse extends TaobaoResponse {
private static final long serialVersionUID = 3164297348793841419L;
/**
* 限时打折对应的商品详情列表。
*/
@ApiListField("item_discount_detail_list")
@ApiField("limit_discount_detail")
private List<LimitDiscountDetail> itemDiscountDetailList;
public void setItemDiscountDetailList(List<LimitDiscountDetail> itemDiscountDetailList) {
this.itemDiscountDetailList = itemDiscountDetailList;
}
public List<LimitDiscountDetail> getItemDiscountDetailList( ) {
return this.itemDiscountDetailList;
}
}
|
[
"bingzhaoliu@gmail.com@28b099c3-0654-7635-3fca-eff556b9d3f2"
] |
bingzhaoliu@gmail.com@28b099c3-0654-7635-3fca-eff556b9d3f2
|
fff9a02c9c99efa35d55a9a6652cf1f913640500
|
8b49b48892f698439ce7ce2e85b4fa3804370c62
|
/src/com/danbro/javase/src/main/java/collection/linkedlist/LinkedListTest1.java
|
a19cbb244f9ec2b2a3f8aeeba8af4f523603cdea
|
[] |
no_license
|
Danbro007/jdk-source-analysis
|
319223e56ea9c3f752e86f258684981d4e95180f
|
bbe0b6acb07be13b59e60bec3fab7ec90d543ad9
|
refs/heads/master
| 2023-01-22T08:42:44.624405
| 2020-12-04T06:15:03
| 2020-12-04T06:15:03
| 277,484,296
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 418
|
java
|
package collection.linkedlist;
import java.util.LinkedList;
/**
* @Classname LinkedListTest1
* @Description TODO
* @Date 2020/8/7 15:37
* @Author Danrbo
*/
public class LinkedListTest1 {
public static void main(String[] args) {
LinkedList<Integer> linkedList = new LinkedList<>();
linkedList.add(1);
linkedList.add(2);
linkedList.add(3);
linkedList.add(2,4);
}
}
|
[
"710170342@qq.com"
] |
710170342@qq.com
|
dc7e7ad8ac2c071d4e5c3bd3b8e242443fc2d6ac
|
b2f44ba766a44426cd06ebfb922d8b75c1773d63
|
/src/com/leetcode/P762_PrimeNumberofSetBitsinBinaryRepresentation.java
|
33ac6e28705deac4784371ef2472ed2781726316
|
[] |
no_license
|
joy32812/leetcode
|
a1179ecff91127a6cda83cf70838354b0670970f
|
9bd74b9774012df0e2e221eedc63d10f3ba88238
|
refs/heads/master
| 2023-08-16T14:11:34.232388
| 2023-08-13T11:30:05
| 2023-08-13T11:30:05
| 81,704,645
| 10
| 5
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 568
|
java
|
package com.leetcode;
import java.util.Arrays;
import java.util.HashSet;
import java.util.Set;
public class P762_PrimeNumberofSetBitsinBinaryRepresentation {
public int countPrimeSetBits(int L, int R) {
Set<Integer> primeSet = new HashSet<>(Arrays.asList(2, 3, 5, 7, 11, 13, 17, 19, 23));
int ans = 0;
for (int i = L; i <= R; i++) {
String binStr = Integer.toBinaryString(i);
int len = binStr.replaceAll("0", "").length();
if (primeSet.contains(len)) ans ++;
}
return ans;
}
}
|
[
"joy32812@qq.com"
] |
joy32812@qq.com
|
f5f0a362c136704f03c0182bdbd4270ffa5386ab
|
80e6e589b26f2311367f2dc512527aa37fb63f09
|
/DesignPattern/src/decorator/ToppingDecorator.java
|
92363b0518ebbb485c43c1b60346f8eea0766c49
|
[] |
no_license
|
antosoa/design-pattern
|
e33f638b6868b5f7d4fc5f027a16a27257b98176
|
c398df1173d8d9d3940c4a0436e5eab698df3668
|
refs/heads/master
| 2022-11-08T03:03:45.819102
| 2020-07-01T14:42:35
| 2020-07-01T14:42:35
| 263,295,394
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 744
|
java
|
// has a "has a" relationship with pizza.
// this is an Aggregation Relationship
/*
* To define a class that does not
* implements all the methods of an
* interface implies that the class
* must be of type Abstract
*
*/
package decorator;
abstract class ToppingDecorator implements Pizza {
protected Pizza tempPizza;
// Assigns the type instance to this attribute
// of a Pizza
// All decorators can dynamically customize the Pizza
// instance PlainPizza because of this
public ToppingDecorator(Pizza newPizza) {
tempPizza = newPizza;
}
public String getDescription() {
return tempPizza.getDescription();
}
public double getCost() {
return tempPizza.getCost();
}
}
|
[
"MY_NAME@example.com"
] |
MY_NAME@example.com
|
bcc945f6fbf1211899648ddd575e4dc99f1bd7a2
|
f37e90775a158ea0ae644e334eac5bba341f4989
|
/Java+/JSE+/Core/test/lang/variable/HideLocalVariablesTest.java
|
30a26aa50e1ff86d591638d9920e825f0775c794
|
[] |
no_license
|
Aleks-Ya/yaal_examples
|
0087bbaf314ca5127051c93b89c8fc2dcd14c1e3
|
ec282968abf1b86e54fc2116c39f2d657b51baac
|
refs/heads/master
| 2023-09-01T07:40:44.404550
| 2023-08-27T15:24:34
| 2023-08-29T22:01:46
| 14,327,752
| 4
| 2
| null | 2021-06-16T20:39:19
| 2013-11-12T09:26:08
|
Java
|
UTF-8
|
Java
| false
| false
| 489
|
java
|
package lang.variable;
import org.junit.jupiter.api.Test;
import static org.assertj.core.api.Assertions.assertThat;
/**
* Сокрытие локальных переменных.
*/
class HideLocalVariablesTest {
@Test
void test() {
Byte[] Byte[] = {{0}};
assertThat(Byte.toString().startsWith("[[Ljava.lang.Byte;@")).isTrue();
assertThat(Byte.class.toString()).isEqualTo("class java.lang.Byte");
assertThat(Byte.length).isEqualTo(1);
}
}
|
[
"ya_al@bk.ru"
] |
ya_al@bk.ru
|
7fda026976559520a65e744b24eefc4fe38381ad
|
be0e7aaf8795a8484a564e462bd72a7df504727c
|
/src/main/java/com/group/webFramework/interceptor/LoginValidateInterceptor.java
|
e20f6f21a5ccaf2ada17910376bae6d0a04da836
|
[] |
no_license
|
water-fu/renshi
|
ff88f977b4383f9df519d254335eec1105fed0c4
|
7dc87ea8c7e7cf2ee856998833550f5b9011e15b
|
refs/heads/master
| 2021-01-19T11:32:33.521431
| 2016-03-26T09:36:48
| 2016-03-26T09:36:48
| 35,823,524
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 5,250
|
java
|
package com.group.webFramework.interceptor;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.web.method.HandlerMethod;
import org.springframework.web.servlet.handler.HandlerInterceptorAdapter;
import org.springframework.web.servlet.resource.ResourceHttpRequestHandler;
import com.group.renshi.bean.system.AccountInfoBean;
import com.group.renshi.constant.SystemConstantType;
import com.group.webFramework.annotation.LoginFilter;
import com.group.webFramework.entity.UserDetails;
import com.group.webFramework.uitl.SessionControl;
/**
* 总体说明
*
* <p>
* 具体说明
* </p>
*
* @author Administrator
* @version $Id: LoginValidateInterceptor.java,v 0.1 2015-5-20 下午5:11:21 Exp $
*/
public class LoginValidateInterceptor extends HandlerInterceptorAdapter {
/**
* preHandle方法是进行处理器拦截用的,顾名思义,该方法将在Controller处理之前进行调用,
* SpringMVC中的Interceptor拦截器是链式的,可以同时存在
* 多个Interceptor,然后SpringMVC会根据声明的前后顺序一个接一个的执行
* ,而且所有的Interceptor中的preHandle方法都会在
* Controller方法调用之前调用。SpringMVC的这种Interceptor链式结构也是可以进行中断的
* ,这种中断方式是令preHandle的返 回值为false,当preHandle的返回值为false的时候整个请求就结束了。
*
* @see org.springframework.web.servlet.HandlerInterceptor#preHandle(javax.servlet.http.HttpServletRequest,
* javax.servlet.http.HttpServletResponse, java.lang.Object)
*/
@Override
public boolean preHandle(HttpServletRequest request,
HttpServletResponse response, Object handler) throws Exception {
if (handler instanceof HandlerMethod) {
HandlerMethod method = (HandlerMethod) handler;
String already = request.getParameter("already");
if (null != already) {
if (1 == Integer.valueOf(already))
return true;
}
LoginFilter loginFilter = method
.getMethodAnnotation(LoginFilter.class);
// 如果没有@LoginFilter注解则跳过拦截
// 判断方法上注解的LoginFilter值,如果否则不拦截
// 判断Session中用户是否存在
UserDetails userDetails = SessionControl.getCurUserDetail(request);
if (null == userDetails || null == userDetails.getAccountInfoBean()) {
if (loginFilter == null || !loginFilter.needLogin()) {
return true;
}
// 如果没有登录,则请求转发到登录页面
request.getRequestDispatcher(
"/WEB-INF/pages/system/accountInfo/login.jsp").forward(
request, response);
return false;
} else {
// 如果是认证的页面则不需要验证
String[] path = new String[] { "/doctor/baseInfo",
"/doctor/authInfo", "/doctor/approve",
"/proxy/authInfo", "/proxy/toAuthInfo",
"/proxy/toApprove", "/common/ajaxFileUpload",
"/common/showImage", "/doctor/getDeptInfo",
"/system/logout", "/", "/system/loginPage" };
String requestPath = request.getServletPath();
for (int i = 0; i < path.length; i++) {
if (requestPath.equalsIgnoreCase(path[i])) {
return true;
}
if (requestPath.indexOf("/admin") > 0) {
return true;
}
}
AccountInfoBean accountInfoBean = userDetails
.getAccountInfoBean();
// 如果登录了,未激活的,跳转到激活页面
if (accountInfoBean.getActiveType() == SystemConstantType.ACTIVE_TYPE_NO) {
response.sendRedirect(request.getContextPath()
+ "/system/activePage?id="
+ accountInfoBean.getAccountId() + "&already=1");//
return false;
}
// 认证步骤
switch (accountInfoBean.getAccountStatus()) {
// 未认证,跳转到第一步
case SystemConstantType.ACCOUNT_STATUS_ZERO:
if ("/doctor/toBaseInfo".equals(requestPath)) {
break;
}
response.sendRedirect(request.getContextPath()
+ "/doctor/toBaseInfo?id="
+ accountInfoBean.getAccountId());
return false;
// 第一步已认证,跳转到第二步
case SystemConstantType.ACCOUNT_STATUS_FIRST:
if ("/doctor/toAuthInfo".equals(requestPath)) {
break;
}
response.sendRedirect(request.getContextPath()
+ "/doctor/toAuthInfo?id="
+ accountInfoBean.getAccountId());
return false;
// 第二步已认证,跳转到第三步
case SystemConstantType.ACCOUNT_STATUS_SECOND:
if ("/doctor/toApprove".equals(requestPath)) {
break;
}
response.sendRedirect(request.getContextPath()
+ "/doctor/toApprove?id="
+ accountInfoBean.getAccountId());
return false;
case SystemConstantType.ACCOUNT_STATUS_THIRD:
if ("/doctor/toApprove".equals(requestPath)) {
response.sendRedirect(request.getContextPath()
+ "/blog/" + accountInfoBean.getAccountId());
return false;
}
break;
}
}
return true;
} else if (handler instanceof ResourceHttpRequestHandler) { // 如果是资源文件则返回true
return true;
}
return false;
}
}
|
[
"fusj@ce2a1918-1c78-4d5b-8570-6b617fc693f1"
] |
fusj@ce2a1918-1c78-4d5b-8570-6b617fc693f1
|
32dca27a6728ff3e0c6beb99f02d0ccfb3b4a390
|
22f641a3761b59000d89a7c85b79b982c4b7b842
|
/src/net/test/chapter15_genericParadigm/Holder.java
|
ac9ef14d5c671a67e670dad8c0a46423b477926c
|
[] |
no_license
|
wuli2496/ThinkingInJava
|
29074a1dde12e7189cec76ddb63fc9974612916c
|
ed9c126f9d497043f71f7adce2591dc9c0d4900a
|
refs/heads/master
| 2021-01-19T08:04:38.948720
| 2020-11-28T16:14:52
| 2020-11-28T16:14:52
| 87,596,094
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 727
|
java
|
package net.test.chapter15_genericParadigm;
public class Holder<T> {
private T value;
public Holder() {}
public Holder(T val) {value = val;}
public void set(T val) {value = val;}
public T get() {return value;}
public boolean equals(Object obj)
{
return value.equals(obj);
}
public static void main(String[] args)
{
Holder<Apple> Apple = new Holder<Apple>(new Apple());
Apple d = Apple.get();
Holder<? extends Fruit> fruit = Apple;
Fruit p = fruit.get();
try {
Orange c = (Orange)fruit.get();
} catch (Exception e) {
System.out.println(e);
}
System.out.println(fruit.equals(d));
}
}
|
[
"wuli2496@163.com"
] |
wuli2496@163.com
|
c0a9157f985758a059392997bb802271ffa20826
|
180e78725121de49801e34de358c32cf7148b0a2
|
/dataset/protocol1/yauaa/learning/2220/TestCaching.java
|
abccc94db9a672e7a6ba3441001fd26f2405dc73
|
[] |
no_license
|
ASSERT-KTH/synthetic-checkstyle-error-dataset
|
40e8d1e0a7ebe7f7711def96a390891a6922f7bd
|
40c057e1669584bfc6fecf789b5b2854660222f3
|
refs/heads/master
| 2023-03-18T12:50:55.410343
| 2019-01-25T09:54:39
| 2019-01-25T09:54:39
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,826
|
java
|
/*
* Yet Another UserAgent Analyzer
* Copyright (C) 2013-2018 Niels Basjes
*
* 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
*
* https://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 nl.basjes.parse.useragent;
import org.apache.commons.collections4.map.LRUMap;
import org.apache.commons.lang3.reflect.FieldUtils;
import org.junit.Test;
import static org.junit.Assert.assertEquals;
public class TestCaching {
@Test
public void testSettingCaching() throws IllegalAccessException {
UserAgentAnalyzer uaa = UserAgentAnalyzer
.newBuilder()
.withCache(42)
.hideMatcherLoadStats()
.withField("AgentUuid")
.build();
assertEquals(42, uaa.getCacheSize());
assertEquals(42, getAllocatedCacheSize(uaa));
uaa.disableCaching();
assertEquals(0, uaa.getCacheSize());
assertEquals(0, getAllocatedCacheSize(uaa));
uaa.setCacheSize(42);
assertEquals(42, uaa.getCacheSize());
assertEquals(42, getAllocatedCacheSize(uaa));
}
@Test
public void testSettingNoCaching() throws IllegalAccessException {
UserAgentAnalyzer uaa = UserAgentAnalyzer
.newBuilder()
.withoutCache()
.hideMatcherLoadStats()
.withField("AgentUuid")
.build();
assertEquals(0, uaa.getCacheSize());
assertEquals(0, getAllocatedCacheSize(uaa));
uaa.setCacheSize(42);
assertEquals(42, uaa.getCacheSize());
assertEquals(42, getAllocatedCacheSize(uaa));
uaa.disableCaching();
assertEquals(0, uaa.getCacheSize());
assertEquals(0, getAllocatedCacheSize(uaa));
}
@Test
public void testCache() throws IllegalAccessException {
String uuid = "11111111-2222-3333-4444-555555555555";
String fieldName = "AgentUuid";
UserAgentAnalyzer uaa = UserAgentAnalyzer
.newBuilder()
.withCache(1)
.hideMatcherLoadStats()
.withField(fieldName)
.build();
UserAgent agent;
assertEquals(1, uaa.getCacheSize());
assertEquals(1, getAllocatedCacheSize(uaa));
agent = uaa.parse(uuid);
assertEquals(uuid, agent.get(fieldName).getValue());
assertEquals(agent, getCache(uaa).get(uuid));
agent = uaa.parse(uuid);
assertEquals(uuid, agent.get(fieldName).getValue());
assertEquals(agent, getCache(uaa).get(uuid));
uaa.disableCaching();
assertEquals(0, uaa.getCacheSize());
assertEquals(0, getAllocatedCacheSize(uaa));
agent = uaa.parse(uuid);
assertEquals(uuid, agent.get(fieldName).getValue());
assertEquals(null, getCache(uaa));
}
private LRUMap<?, ?> getCache(UserAgentAnalyzer uaa) throws IllegalAccessException {
LRUMap<?, ?> actualCache = null;
Object rawParseCache = FieldUtils.readField(uaa, "parseCache", true);
if (rawParseCache instanceof LRUMap<?, ?>) {
actualCache = (LRUMap) rawParseCache;
}
return actualCache;
}
private int getAllocatedCacheSize(UserAgentAnalyzer uaa) throws IllegalAccessException {
LRUMap<?, ?> cache = getCache(uaa);
if (cache == null) {
return 0;
}
return cache.maxSize();
}
}
|
[
"bloriot97@gmail.com"
] |
bloriot97@gmail.com
|
749ffb2e625cb1089cdad5f3960657e2483a2a43
|
72f77450eb99de6de59f44206cc663b22e57b016
|
/study_java/study-java-moreThread/src/main/java/top/mcwebsite/moreThread/suspend_resume_LockStop/Run.java
|
05bc4e06145e205d1f61ab9dd71c0696303d8e2f
|
[] |
no_license
|
woxin123/Java-Study
|
27a09b34a954dc0294f62944fa79be02d6ae8029
|
f569c4fe27fa65f88232d246906aa67f9ab9d4ba
|
refs/heads/master
| 2022-12-17T01:43:03.476391
| 2019-06-17T07:07:58
| 2019-06-17T07:07:58
| 105,738,558
| 2
| 0
| null | 2022-12-16T06:40:00
| 2017-10-04T06:35:48
|
JavaScript
|
UTF-8
|
Java
| false
| false
| 470
|
java
|
package top.mcwebsite.moreThread.suspend_resume_LockStop;
/**
* @author mengchen
* @time 18-8-16 上午11:29
*/
public class Run {
public static void main(String[] args) {
try {
MyThread thread = new MyThread();
thread.start();
Thread.sleep(1000);
thread.suspend();
System.out.println("main end");
} catch (InterruptedException e) {
e.printStackTrace();
}
}
}
|
[
"1293141942@qq.com"
] |
1293141942@qq.com
|
5a56b0646c0597c145026d2e8dcd55ec9d7dc09f
|
4aa6a548ec56dad89d5c3e2dfc2de4c3a0e32707
|
/src/test/java/io/cozmic/usher/test/integration/CozmicBot.java
|
811bbaa4baff0e976e281e686cd4bacf6c02e137
|
[
"Apache-2.0"
] |
permissive
|
wired-mind/usher
|
225a3bf9bce7f705f025d5d44da257945b5bece1
|
9eeead8d8d0a583c8f3835ed68c70f5d64da1692
|
refs/heads/master
| 2020-03-29T16:31:16.549804
| 2016-01-20T22:52:02
| 2016-01-20T22:52:02
| 24,872,772
| 3
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,245
|
java
|
package io.cozmic.usher.test.integration;
import io.vertx.core.AbstractVerticle;
import io.vertx.core.AsyncResult;
import io.vertx.core.Future;
import io.vertx.core.Handler;
import io.vertx.core.buffer.Buffer;
import io.vertx.core.logging.Logger;
import io.vertx.core.logging.LoggerFactory;
import io.vertx.core.net.NetClient;
import io.vertx.core.net.NetSocket;
import io.vertx.core.parsetools.RecordParser;
import io.vertx.core.streams.Pump;
import io.vertx.core.streams.ReadStream;
/**
* Created by chuck on 10/3/14.
*/
public class CozmicBot extends AbstractVerticle {
public static final String COZMICBOT_RESULT = "COZMICBOT_RESULT";
Logger logger = LoggerFactory.getLogger(CozmicBot.class.getName());
private NetClient netClient;
public void start(final Future<Void> startedResult) {
final int repeat = config().getInteger("repeat", 1).intValue();
final byte[] bytes = config().getBinary("buffer", new byte[]{});
final Buffer buffer = Buffer.buffer(bytes);
netClient = vertx.createNetClient();
// .setConnectTimeout(5000).setReconnectAttempts(100).setReconnectInterval(1000);
netClient.connect(2500, "localhost", new Handler<AsyncResult<NetSocket>>() {
@Override
public void handle(AsyncResult<NetSocket> event) {
if (event.failed()) {
logger.error(event.cause().getMessage());
startedResult.fail(event.cause());
return;
}
final NetSocket socket = event.result();
final RecordParser responseParser = RecordParser.newFixed(2, new Handler<Buffer>() {
int socketReceiveCount = 0;
@Override
public void handle(Buffer event) {
socketReceiveCount++;
if (socketReceiveCount == repeat) {
socket.handler(null);
socket.close();
}
vertx.eventBus().send(COZMICBOT_RESULT, event);
}
});
socket.handler(responseParser);
socket.exceptionHandler(new Handler<Throwable>() {
@Override
public void handle(Throwable event) {
logger.error("Socket error from test client", event);
}
});
Pump.pump(new DataStream(buffer, repeat), socket).start();
socket.closeHandler(new Handler<Void>() {
@Override
public void handle(Void event) {
// getContainer().logger().info("Bloody hell");
}
});
}
});
startedResult.complete();
}
private static class DataStream implements ReadStream<Buffer> {
private final Buffer buffer;
private final int repeat;
private boolean paused;
private int count = 0;
private Handler<Buffer> dataHandler;
public DataStream(Buffer buffer, int repeat) {
this.buffer = buffer;
this.repeat = repeat;
}
@Override
public ReadStream<Buffer> endHandler(Handler<Void> endHandler) {
return this;
}
@Override
public ReadStream<Buffer> handler(Handler<Buffer> handler) {
this.dataHandler = handler;
if (dataHandler != null) doGenerateData();
return this;
}
protected void doGenerateData() {
while (!paused && count < repeat) {
count++;
dataHandler.handle(buffer);
}
}
@Override
public ReadStream<Buffer> pause() {
paused = true;
return this;
}
@Override
public ReadStream<Buffer> resume() {
paused = false;
if (dataHandler != null) doGenerateData();
return this;
}
@Override
public ReadStream<Buffer> exceptionHandler(Handler<Throwable> handler) {
return this;
}
}
}
|
[
"cswanberg@mad-swan.com"
] |
cswanberg@mad-swan.com
|
a12143fec57bc52c58b3b3f2d18ce60fae1353ff
|
205d18401445f4bb5e955e270b0f072202b0ec22
|
/algorithms/passive/rpni/src/test/java/de/learnlib/algorithms/rpni/it/RpniDfaIT.java
|
3490008390fe30dbce4156896cce9d5596f754c2
|
[
"Apache-2.0",
"LicenseRef-scancode-free-unknown"
] |
permissive
|
damascenodiego/learnlib
|
b56d07bb904a9b6a770496e09bac687304dee053
|
09b7f505bcee188efe4605a038536a36a2e4c98c
|
refs/heads/develop
| 2021-06-04T12:26:36.840535
| 2018-11-26T19:02:56
| 2018-11-26T19:02:56
| 159,353,246
| 0
| 0
|
Apache-2.0
| 2021-02-18T09:46:00
| 2018-11-27T15:02:47
|
Java
|
UTF-8
|
Java
| false
| false
| 1,739
|
java
|
/* Copyright (C) 2013-2018 TU Dortmund
* This file is part of LearnLib, http://www.learnlib.de/.
*
* 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 de.learnlib.algorithms.rpni.it;
import de.learnlib.algorithms.rpni.BlueFringeRPNIDFA;
import de.learnlib.testsupport.it.learner.AbstractDFAPassiveLearnerIT;
import de.learnlib.testsupport.it.learner.PassiveLearnerVariantList;
import net.automatalib.automata.fsa.DFA;
import net.automatalib.words.Alphabet;
public class RpniDfaIT extends AbstractDFAPassiveLearnerIT {
@Override
protected <I> void addLearnerVariants(Alphabet<I> alphabet,
PassiveLearnerVariantList<DFA<?, I>, I, Boolean> variants) {
final boolean[] determinism = {true, false};
final boolean[] parallelism = {true, false};
for (final boolean d : determinism) {
for (final boolean p : parallelism) {
final BlueFringeRPNIDFA<I> learner = new BlueFringeRPNIDFA<>(alphabet);
learner.setParallel(p);
learner.setDeterministic(d);
variants.addLearnerVariant(String.format("BlueFringeRPNIDFA, det=%b, par=%b", d, p), learner);
}
}
}
}
|
[
"markus.frohme@udo.edu"
] |
markus.frohme@udo.edu
|
3772aac65783bbb7016b8bd6277f1c80705bb297
|
ba1db0d1de362207439417a783361db9d0fe9869
|
/src/main/java/io/weli/tracing/Foo.java
|
c013817e4be897d113a2ddad2091d6d45203e928
|
[] |
no_license
|
liweinan/resteasy-tracing-example
|
3cd838feb1029a71940e7f2447eda9835758a0b8
|
cfa3605689e9cee32f29f2865ac539d61d5608f6
|
refs/heads/master
| 2021-06-30T09:16:11.250199
| 2019-03-20T08:02:51
| 2019-03-20T08:02:51
| 131,037,483
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 139
|
java
|
package io.weli.tracing;
import javax.ws.rs.GET;
public class Foo {
@GET
public String get() {
return "{|FOO|}";
}
}
|
[
"l.weinan@gmail.com"
] |
l.weinan@gmail.com
|
1c6b7dbc0b4cb02dd056e1f2f0b7bee3fe4e82e9
|
b0cce84067ea5d37bf126bf671620a15b9d90890
|
/app/src/main/java/com/mouqu/zhailu/zhailu/base/BasePresenter.java
|
d9ddaa2a97d32139fd4dccd50d1da717c9a2be97
|
[] |
no_license
|
18668197127/ZhailuQB
|
f4df02dda885c5c8f19ef67857374f4b388542bd
|
846f5d29df4d2c2fa7bad2f6239a2e41701e2c11
|
refs/heads/master
| 2020-04-17T16:30:39.044861
| 2019-01-21T03:39:06
| 2019-01-21T03:39:06
| 166,743,120
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 468
|
java
|
package com.mouqu.zhailu.zhailu.base;
import com.mouqu.zhailu.zhailu.net.RxManager;
public abstract class BasePresenter<V, M > {
public M mModel;
public V mView;
public RxManager rxManager = new RxManager();
public void setVM(V v, M m) {
this.mView = v;
this.mModel = m;
}
/**
* 防止内存泄漏
*/
public void onDestroy() {
rxManager.clear();
rxManager = null;
mView = null;
}
}
|
[
"1013273644@qq.com"
] |
1013273644@qq.com
|
7c6a69312063a50e401896dd9b51c205de774301
|
f081da8f16da9cd23d03659e96925a47ac12f068
|
/src/main/java/BP/WF/XML/CCMenuAttr.java
|
1f01922e70a7eee2debb64e12932ab48406e80bd
|
[] |
no_license
|
konglong123/KFlow
|
df671510d601724d1cb5ee1efd52a172c7915dcf
|
01fc4a782791df8e800b26bdd3f3abc6dd83259b
|
refs/heads/master
| 2023-02-02T15:14:12.531378
| 2020-12-24T11:15:10
| 2020-12-24T11:15:10
| 228,565,169
| 1
| 2
| null | 2020-06-15T07:02:17
| 2019-12-17T08:06:36
|
JavaScript
|
UTF-8
|
Java
| false
| false
| 204
|
java
|
package BP.WF.XML;
/**
抄送菜单属性
*/
public class CCMenuAttr
{
/**
编号
*/
public static final String No = "No";
/**
名称
*/
public static final String Name = "Name";
}
|
[
"17888821571@163.com"
] |
17888821571@163.com
|
b7a61cc6dc1e85479536970a9dfd0d6da008742b
|
58da62dfc6e145a3c836a6be8ee11e4b69ff1878
|
/src/main/java/com/alipay/api/response/AlipayOpenMiniInnerbaseinfoBatchqueryResponse.java
|
acbd8c4dd5791465b7b371638131db690abe9d3a
|
[
"Apache-2.0"
] |
permissive
|
zhoujiangzi/alipay-sdk-java-all
|
00ef60ed9501c74d337eb582cdc9606159a49837
|
560d30b6817a590fd9d2c53c3cecac0dca4449b3
|
refs/heads/master
| 2022-12-26T00:27:31.553428
| 2020-09-07T03:39:05
| 2020-09-07T03:39:05
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 977
|
java
|
package com.alipay.api.response;
import java.util.List;
import com.alipay.api.internal.mapping.ApiField;
import com.alipay.api.internal.mapping.ApiListField;
import com.alipay.api.domain.MiniAppBaseInfoQueryResponse;
import com.alipay.api.AlipayResponse;
/**
* ALIPAY API: alipay.open.mini.innerbaseinfo.batchquery response.
*
* @author auto create
* @since 1.0, 2020-04-23 14:18:52
*/
public class AlipayOpenMiniInnerbaseinfoBatchqueryResponse extends AlipayResponse {
private static final long serialVersionUID = 4666772896213838843L;
/**
* 小程序基本信息
*/
@ApiListField("base_info_list")
@ApiField("mini_app_base_info_query_response")
private List<MiniAppBaseInfoQueryResponse> baseInfoList;
public void setBaseInfoList(List<MiniAppBaseInfoQueryResponse> baseInfoList) {
this.baseInfoList = baseInfoList;
}
public List<MiniAppBaseInfoQueryResponse> getBaseInfoList( ) {
return this.baseInfoList;
}
}
|
[
"ben.zy@antfin.com"
] |
ben.zy@antfin.com
|
f5c26df65fc4b9220e42e2941eeceb78938d0c8e
|
8a43ca36a71b430096c609e96889aae94e93ddc9
|
/spincast-plugins/spincast-plugins-http-client-parent/spincast-plugins-http-client/src/main/java/org/spincast/plugins/httpclient/builders/PostRequestBuilderDefault.java
|
669e1f3613fd810bf5381a7adf8fc092925446b3
|
[
"Apache-2.0"
] |
permissive
|
spincast/spincast-framework
|
18163ee0d5ed3571113ad6f3112cf7f951eee910
|
fc25e6e61f1d20643662ed94e42003b23fe651f6
|
refs/heads/master
| 2022-10-20T11:20:43.008571
| 2022-10-11T23:21:41
| 2022-10-11T23:21:41
| 56,924,959
| 48
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,803
|
java
|
package org.spincast.plugins.httpclient.builders;
import org.spincast.core.cookies.CookieFactory;
import org.spincast.core.json.JsonManager;
import org.spincast.core.xml.XmlManager;
import org.spincast.plugins.httpclient.HttpResponseFactory;
import org.spincast.plugins.httpclient.SpincastHttpClientConfig;
import org.spincast.plugins.httpclient.utils.SpincastHttpClientUtils;
import org.spincast.shaded.org.apache.http.client.methods.HttpEntityEnclosingRequestBase;
import org.spincast.shaded.org.apache.http.client.methods.HttpPost;
import com.google.inject.assistedinject.Assisted;
import com.google.inject.assistedinject.AssistedInject;
/**
* Implementation for the Http Client builder for a POST request.
*/
public class PostRequestBuilderDefault extends BodySenderRequestBuilderBaseDefault<PostRequestBuilder>
implements PostRequestBuilder {
@AssistedInject
public PostRequestBuilderDefault(@Assisted String url,
CookieFactory cookieFactory,
HttpResponseFactory spincastHttpResponseFactory,
JsonManager jsonManager,
XmlManager xmlManager,
SpincastHttpClientUtils spincastHttpClientUtils,
SpincastHttpClientConfig spincastHttpClientConfig) {
super(url,
cookieFactory,
spincastHttpResponseFactory,
jsonManager,
xmlManager,
spincastHttpClientUtils,
spincastHttpClientConfig);
}
@Override
protected HttpEntityEnclosingRequestBase getHttpEntityEnclosingRequestBase(String url) {
return new HttpPost(url);
}
}
|
[
"electrotype@gmail.com"
] |
electrotype@gmail.com
|
1c3efbb56e665ee259226d505f077760fc12a8cc
|
2fda0a2f1f5f5d4e7d72ff15a73a4d3e1e93abeb
|
/proFL-plugin-2.0.3/com/mks/api/ext/CommandSelection.java
|
34c118a1ef0523d156b76379a0099f3615bdd650
|
[
"MIT"
] |
permissive
|
ycj123/Research-Project
|
d1a939d99d62dc4b02d9a8b7ecbf66210cceb345
|
08296e0075ba0c13204944b1bc1a96a7b8d2f023
|
refs/heads/main
| 2023-05-29T11:02:41.099975
| 2021-06-08T13:33:26
| 2021-06-08T13:33:26
| 374,899,147
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 601
|
java
|
//
// Decompiled by Procyon v0.5.36
//
package com.mks.api.ext;
public abstract class CommandSelection
{
public abstract int getSize();
public abstract String nextItem();
public abstract boolean hasNext();
public abstract void startSelection();
public abstract void endSelection();
public String[] toArgs() {
final int size = this.getSize();
final String[] args = new String[size];
this.startSelection();
for (int i = 0; i < size; ++i) {
args[i] = this.nextItem();
}
return args;
}
}
|
[
"chijiang.yang@student.unimelb.edu.au"
] |
chijiang.yang@student.unimelb.edu.au
|
305f99641e33e6c799731fa37b07df3bab486353
|
1f45dafb232759e3028b7d524cf708dc2a31d1b3
|
/gc program/gc/jini/com/sun/jini/jeri/internal/runtime/CharacterEncoder.java
|
22c41f25593ce12a41c8d1241ee08e7b0b0e3506
|
[] |
no_license
|
gcsr/btech-practice-codes
|
06eacfeb6a7074b2244383a6110f77abdfc052b3
|
f95a79f23484740d82eebe24763996beddd1ace7
|
refs/heads/master
| 2022-11-19T17:37:39.220405
| 2020-07-23T18:17:58
| 2020-07-23T18:17:58
| 263,967,369
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 7,941
|
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 com.sun.jini.jeri.internal.runtime;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintStream;
/**
* This class defines the encoding half of character encoders.
* A character encoder is an algorithm for transforming 8 bit binary
* data into text (generally 7 bit ASCII or 8 bit ISO-Latin-1 text)
* for transmission over text channels such as e-mail and network news.
*
* The character encoders have been structured around a central theme
* that, in general, the encoded text has the form:
*
* <pre>
* [Buffer Prefix]
* [Line Prefix][encoded data atoms][Line Suffix]
* [Buffer Suffix]
* </pre>
*
* In the CharacterEncoder and CharacterDecoder classes, one complete
* chunk of data is referred to as a <i>buffer</i>. Encoded buffers
* are all text, and decoded buffers (sometimes just referred to as
* buffers) are binary octets.
*
* To create a custom encoder, you must, at a minimum, override three
* abstract methods in this class.
* <DL>
* <DD>bytesPerAtom which tells the encoder how many bytes to
* send to encodeAtom
* <DD>encodeAtom which encodes the bytes sent to it as text.
* <DD>bytesPerLine which tells the encoder the maximum number of
* bytes per line.
* </DL>
*
* Several useful encoders have already been written and are
* referenced in the See Also list below.
*
* @author Sun Microsystems, Inc.
*
*/
public abstract class CharacterEncoder {
/** Stream that understands "printing" */
protected PrintStream pStream;
/** Return the number of bytes per atom of encoding */
abstract protected int bytesPerAtom();
/** Return the number of bytes that can be encoded per line */
abstract protected int bytesPerLine();
/**
* Encode the prefix for the entire buffer. By default is simply
* opens the PrintStream for use by the other functions.
*/
protected void encodeBufferPrefix(OutputStream aStream) throws IOException {
pStream = new PrintStream(aStream);
}
/**
* Encode the suffix for the entire buffer.
*/
protected void encodeBufferSuffix(OutputStream aStream) throws IOException {
}
/**
* Encode the prefix that starts every output line.
*/
protected void encodeLinePrefix(OutputStream aStream, int aLength)
throws IOException {
}
/**
* Encode the suffix that ends every output line. By default
* this method just prints a <newline> into the output stream.
*/
protected void encodeLineSuffix(OutputStream aStream) throws IOException {
pStream.println();
}
/** Encode one "atom" of information into characters. */
abstract protected void encodeAtom(OutputStream aStream, byte someBytes[],
int anOffset, int aLength) throws IOException;
/**
* This method works around the bizarre semantics of BufferedInputStream's
* read method.
*/
protected int readFully(InputStream in, byte buffer[])
throws java.io.IOException {
for (int i = 0; i < buffer.length; i++) {
int q = in.read();
if (q == -1)
return i;
buffer[i] = (byte)q;
}
return buffer.length;
}
/**
* Encode bytes from the input stream, and write them as text characters
* to the output stream. This method will run until it exhausts the
* input stream, but does not print the line suffix for a final
* line that is shorter than bytesPerLine().
*/
public void encode(InputStream inStream, OutputStream outStream)
throws IOException {
int j;
int numBytes;
byte tmpbuffer[] = new byte[bytesPerLine()];
encodeBufferPrefix(outStream);
while (true) {
numBytes = readFully(inStream, tmpbuffer);
if (numBytes == 0) {
break;
}
encodeLinePrefix(outStream, numBytes);
for (j = 0; j < numBytes; j += bytesPerAtom()) {
if ((j + bytesPerAtom()) <= numBytes) {
encodeAtom(outStream, tmpbuffer, j, bytesPerAtom());
} else {
encodeAtom(outStream, tmpbuffer, j, (numBytes)- j);
}
}
if (numBytes < bytesPerLine()) {
break;
} else {
encodeLineSuffix(outStream);
}
}
encodeBufferSuffix(outStream);
}
/**
* Encode the buffer in <i>aBuffer</i> and write the encoded
* result to the OutputStream <i>aStream</i>.
*/
public void encode(byte aBuffer[], OutputStream aStream)
throws IOException {
ByteArrayInputStream inStream = new ByteArrayInputStream(aBuffer);
encode(inStream, aStream);
}
/**
* A 'streamless' version of encode that simply takes a buffer of
* bytes and returns a string containing the encoded buffer.
*/
public String encode(byte aBuffer[]) {
ByteArrayOutputStream outStream = new ByteArrayOutputStream();
ByteArrayInputStream inStream = new ByteArrayInputStream(aBuffer);
String retVal = null;
try {
encode(inStream, outStream);
// explicit ascii->unicode conversion
retVal = outStream.toString("8859_1");
} catch (Exception IOException) {
// This should never happen.
throw new Error("CharacterEncoder::encodeBuffer internal error");
}
return (retVal);
}
/**
* Encode bytes from the input stream, and write them as text characters
* to the output stream. This method will run until it exhausts the
* input stream. It differs from encode in that it will add the
* line at the end of a final line that is shorter than bytesPerLine().
*/
public void encodeBuffer(InputStream inStream, OutputStream outStream)
throws IOException {
int j;
int numBytes;
byte tmpbuffer[] = new byte[bytesPerLine()];
encodeBufferPrefix(outStream);
while (true) {
numBytes = readFully(inStream, tmpbuffer);
if (numBytes == 0) {
break;
}
encodeLinePrefix(outStream, numBytes);
for (j = 0; j < numBytes; j += bytesPerAtom()) {
if ((j + bytesPerAtom()) <= numBytes) {
encodeAtom(outStream, tmpbuffer, j, bytesPerAtom());
} else {
encodeAtom(outStream, tmpbuffer, j, (numBytes)- j);
}
}
encodeLineSuffix(outStream);
if (numBytes < bytesPerLine()) {
break;
}
}
encodeBufferSuffix(outStream);
}
/**
* Encode the buffer in <i>aBuffer</i> and write the encoded
* result to the OutputStream <i>aStream</i>.
*/
public void encodeBuffer(byte aBuffer[], OutputStream aStream)
throws IOException {
ByteArrayInputStream inStream = new ByteArrayInputStream(aBuffer);
encodeBuffer(inStream, aStream);
}
/**
* A 'streamless' version of encode that simply takes a buffer of
* bytes and returns a string containing the encoded buffer.
*/
public String encodeBuffer(byte aBuffer[]) {
ByteArrayOutputStream outStream = new ByteArrayOutputStream();
ByteArrayInputStream inStream = new ByteArrayInputStream(aBuffer);
try {
encodeBuffer(inStream, outStream);
} catch (Exception IOException) {
// This should never happen.
throw new Error("CharacterEncoder::encodeBuffer internal error");
}
return (outStream.toString());
}
}
|
[
"gc.sekhar002@gmail.com"
] |
gc.sekhar002@gmail.com
|
5c4f4bb026921a8fc34d89e6ae20d697e6c2e273
|
7df62a93d307a01b1a42bb858d6b06d65b92b33b
|
/src/com/afunms/realtime/CPUControler.java
|
1f79cba2e0fdc09cbb22f14d0e8cc7ca11de8b17
|
[] |
no_license
|
wu6660563/afunms_fd
|
79ebef9e8bca4399be338d1504faf9630c42a6e1
|
3fae79abad4f3eb107f1558199eab04e5e38569a
|
refs/heads/master
| 2021-01-10T01:54:38.934469
| 2016-01-05T09:16:38
| 2016-01-05T09:16:38
| 48,276,889
| 0
| 1
| null | null | null | null |
GB18030
|
Java
| false
| false
| 8,511
|
java
|
package com.afunms.realtime;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Hashtable;
import java.util.List;
import java.util.Vector;
import javax.servlet.ServletContext;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import org.apache.log4j.Logger;
import com.afunms.common.util.SysLogger;
import com.afunms.indicators.dao.NodeGatherIndicatorsDao;
import com.afunms.indicators.model.NodeDTO;
import com.afunms.indicators.model.NodeGatherIndicators;
import com.afunms.indicators.util.Constant;
import com.afunms.indicators.util.NodeUtil;
import com.afunms.monitor.executor.base.SnmpMonitor;
import com.afunms.polling.PollingEngine;
import com.afunms.polling.impl.HostCollectDataManager;
import com.afunms.polling.node.Host;
import com.afunms.polling.om.CPUcollectdata;
import com.afunms.polling.snmp.cpu.H3CCpuSnmp;
import com.afunms.polling.snmp.cpu.WindowsCpuSnmp;
/********************************************************
*Title:CPU 利用率 amcharts 生成数据文件
*Description: 目前只支持Windows和H3C的CPU数据采集
*Company dhcc
*@author zhangcw
* 2011-3-4 下午12:41:49
********************************************************
*/
public class CPUControler extends SnmpMonitor{
private Logger logger=Logger.getLogger(CPUControler.class);
private Queue queue=null;
public static void main(String args[]) {
}
/**
* 生成数据
* @param fileName 文件名
* @param blackFlag 是否是要生成初始化数据
* @param nodeID
* @param cx
* @return
*/
@SuppressWarnings("deprecation")
public String generateData(String fileName,boolean blackFlag,int nodeID,HttpServletRequest rq,ServletContext cx){
String webAppPath=cx.getRealPath("/");
String path=webAppPath+"amcharts_data/"+fileName;
//SysLogger.info("The amcharts data path is:"+path);
HttpSession session=rq.getSession();
this.queue=(Queue)session.getAttribute("cpuqueue");
if(null==this.queue){
this.queue=new Queue();
}
if(true==blackFlag){//生成空文件 前n-1个数据为null 最后一个数据为0.0
this.queue.initWithLastData(0.0);
this.queue.setDataList(false);//不是真实数据
session.setAttribute("cpuqueue", this.queue);
}else{
DataModel dm=null;
dm=getCPUData(nodeID);// 采集数据
if(null==dm){//采集数据失败
return "failed:采集数据失败";
}else{
if(false==this.queue.isDataList()){
this.queue.getList().removeLast();//将初始化的0值去掉
this.queue.setDataList(true);
}
this.queue.enqueue(dm);
session.setAttribute("cpuqueue", this.queue);
}
}
SysLogger.info("The nodeID is:"+nodeID);
int size=this.queue.getLENGTH();
SimpleDateFormat smft=new SimpleDateFormat("ss");//设置日期格式
String date;
String data;
StringBuffer dataXML=new StringBuffer("");
dataXML.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
dataXML.append("<chart><series>");
for(int i=0;i<size;i++){
date=smft.format(this.queue.getList().get(i).getDate());
// <value xid="0">1850</value>
dataXML.append("<value xid=\"").append(i).append("\">").append(date).append("</value>");
}
dataXML.append("</series><graphs><graph gid=\"0\">");
for(int i=0;i<size;i++){
data=this.queue.getList().get(i).getData()+"";
// <value xid="0">-0.447</value>
dataXML.append("<value xid=\"").append(i).append("\">").append(data).append("</value>");
}
dataXML.append("</graph></graphs></chart>");
write(path, dataXML.toString());
return "success";
}
/**
* 写文件
* @param path
* @param content
* void
*/
public void write(String path, String content) {
try {
File f = new File(path);
if (f.exists()) {
f.delete();
f.createNewFile();
} else {
if (f.createNewFile()) {
} else {
logger.error("文件创建失败!");
}
}
BufferedWriter output = new BufferedWriter(new FileWriter(f));
output.write(content);
output.close();
} catch (Exception e) {
e.printStackTrace();
}
}
/**
* 采集数据
* @param nodeID
* @return
*/
@SuppressWarnings("unchecked")
public DataModel getCPUData(int nodeID){
DataModel dm=new DataModel();
Host hostNode = (Host)PollingEngine.getInstance().getNodeByID(nodeID);
if(null==hostNode){
SysLogger.info("该节点不存在,不能采集数据!");
return null;
}else if(!hostNode.isManaged()){
SysLogger.info("该节点被管理,不能采集数据!");//被管理是什么意思?不懂。。。。此处参考WindowsCpuSnmp.java
return null;
}
List<NodeGatherIndicators> gatherlist = new ArrayList<NodeGatherIndicators>();
NodeDTO nodeDTO = null;// * 此类为基准性能监控指标
NodeUtil nodeutil = new NodeUtil();//此类为 通过 类型 和 子类型来 获取 设备
nodeDTO = nodeutil.creatNodeDTOByNode(hostNode);
NodeGatherIndicatorsDao indicatorsdao = new NodeGatherIndicatorsDao();//设备性能监控指标 dao
try {
if(Constant.TYPE_HOST.equalsIgnoreCase(nodeDTO.getType())){//服务器
if (Constant.TYPE_HOST_SUBTYPE_WINDOWS.equalsIgnoreCase(nodeDTO.getSubtype())) {//windows服务器
gatherlist = indicatorsdao.findByNodeIdAndTypeAndSubtype(hostNode.getId()+"", nodeDTO.getType(), nodeDTO.getSubtype());
}
}else if(Constant.TYPE_NET.equalsIgnoreCase(nodeDTO.getType())){//网络设备
if (Constant.TYPE_NET_SUBTYPE_H3C.equalsIgnoreCase(nodeDTO.getSubtype())) {//H3C
gatherlist = indicatorsdao.findByNodeIdAndTypeAndSubtype(hostNode.getId()+"", nodeDTO.getType(), nodeDTO.getSubtype());
}
}
} catch (Exception e) {
e.printStackTrace();
} finally {
indicatorsdao.close();
}
/**Window 服务器CPU数据采集**/
if(Constant.TYPE_HOST.equalsIgnoreCase(nodeDTO.getType())&&Constant.TYPE_HOST_SUBTYPE_WINDOWS.equalsIgnoreCase(nodeDTO.getSubtype())){
if (gatherlist != null && gatherlist.size() > 0) {
for (int i = 0; i < gatherlist.size(); i++) {
NodeGatherIndicators nodeGatherIndicators = (NodeGatherIndicators) gatherlist.get(i);
if ("cpu".equalsIgnoreCase(nodeGatherIndicators.getName())) {
// 进行CPU利用率的采集
WindowsCpuSnmp windowsCpuSnmp=null;
try {
windowsCpuSnmp = (WindowsCpuSnmp) Class.forName(
"com.afunms.polling.snmp.cpu.WindowsCpuSnmp").newInstance();
Hashtable returnHash = windowsCpuSnmp.collect_Data(nodeGatherIndicators);
HostCollectDataManager hostdataManager = new HostCollectDataManager();
hostdataManager.createHostItemData(hostNode.getIpAddress(),
returnHash, "host", "windows", "cpu");
Vector cpuUseRatio = (Vector) returnHash.get("cpu");
if (cpuUseRatio != null && cpuUseRatio.size() > 0) {
CPUcollectdata cpudata = (CPUcollectdata) cpuUseRatio.get(0);
dm.setData(Double.valueOf(cpudata.getThevalue()));
dm.setDate(cpudata.getCollecttime().getTime());
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
}
}
/**H3C CPU数据采集**/
else if(Constant.TYPE_NET.equalsIgnoreCase(nodeDTO.getType())&&Constant.TYPE_NET_SUBTYPE_H3C.equalsIgnoreCase(nodeDTO.getSubtype())){
if (gatherlist != null && gatherlist.size() > 0) {
for (int i = 0; i < gatherlist.size(); i++) {
NodeGatherIndicators nodeGatherIndicators = (NodeGatherIndicators) gatherlist.get(i);
if ("cpu".equalsIgnoreCase(nodeGatherIndicators.getName())) {
// 进行CPU利用率的采集
H3CCpuSnmp h3cCpuSnmp=null;
try {
h3cCpuSnmp = (H3CCpuSnmp) Class.forName(
"com.afunms.polling.snmp.cpu.H3CCpuSnmp").newInstance();
Hashtable returnHash = h3cCpuSnmp.collect_Data(nodeGatherIndicators);
HostCollectDataManager hostdataManager = new HostCollectDataManager();
hostdataManager.createHostItemData(hostNode.getIpAddress(),
returnHash, "host", "h3c", "cpu");
Vector cpuUseRatio = (Vector) returnHash.get("cpu");
if (cpuUseRatio != null && cpuUseRatio.size() > 0) {
CPUcollectdata cpudata = (CPUcollectdata) cpuUseRatio.get(0);
dm.setData(Double.valueOf(cpudata.getThevalue()));
dm.setDate(cpudata.getCollecttime().getTime());
}
} catch (Exception e) {
e.printStackTrace();
}
}
}
}
}else {
SysLogger.info("不支持该设备的CPU数据采集!");
return null;
}
return dm;
}
}
|
[
"nick@comprame.com"
] |
nick@comprame.com
|
8857aa606689c4c9c3fab21a5fa767f32ebe8a02
|
977d57af6902757f565897083ee6d6a6c04765d7
|
/basics/ioc/src/main/java/com/tw/ioc/binder/Binding.java
|
4b42ba1aa03fb0cdf8760b6e6fde117ead5a04ad
|
[] |
no_license
|
HFCherish/training-tasks
|
4050678c24ba1998b84a084aa8ac4426a7e0a274
|
5c0d992b7861955bff1ece196c47802677b49471
|
refs/heads/master
| 2021-06-11T19:39:04.778889
| 2017-01-04T06:25:41
| 2017-01-04T06:25:41
| 74,478,706
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 903
|
java
|
package com.tw.ioc.binder;
import com.tw.ioc.Provider;
import com.tw.ioc.Scope;
import java.lang.annotation.Annotation;
/**
* Created by pzzheng on 12/20/16.
*/
public class Binding<T> {
Class<T> toInjectClass;
Provider<T> provider;
Class<? extends Annotation> annotationType;
Scope scope;
public Binding(Class<T> toInjectClass, Provider<T> provider, Class<? extends Annotation> annotationType, Scope scope) {
this.toInjectClass = toInjectClass;
this.provider = provider;
this.annotationType = annotationType;
this.scope = scope;
}
public Class<T> getToInjectClass() {
return toInjectClass;
}
public Provider<T> getProvider() {
return provider;
}
public Class<? extends Annotation> getAnnotationType() {
return annotationType;
}
public Scope getScope() {
return scope;
}
}
|
[
"hf_cherish@163.com"
] |
hf_cherish@163.com
|
a98f071f871b07e9e62637192ccc092a4c9195c3
|
a5f70807c4c818a51077d40642f7539fcdfb0151
|
/src/com/wxad/online/persistence/AppInfoMapper.java
|
e1ac2cab0e7b5b1622438d0648f0a72837338752
|
[] |
no_license
|
tuziilm/online
|
22648a0bcb767a1567405fe09da446e196c75bec
|
35a25aa100452af8770db881eedae5f813356031
|
refs/heads/master
| 2021-01-10T03:02:12.036565
| 2015-12-11T07:05:49
| 2015-12-11T07:05:49
| 46,915,967
| 0
| 0
| null | null | null | null |
GB18030
|
Java
| false
| false
| 602
|
java
|
package com.wxad.online.persistence;
import java.util.List;
import com.wxad.online.domain.ActiveInfo;
import com.wxad.online.domain.AppInfo;
import com.wxad.online.domain.DeleteInfo;
import com.wxad.online.domain.PushRuleInfo;
import com.wxad.online.domain.RegisterInfo;
import com.wxad.online.domain.UpdateInfo;
/**
* ibatis操作系统用户表的Mapper接口
* @author <a href="xuzhenqin@gmail.com">Calvin Pang</a>
*
*/
public interface AppInfoMapper extends BaseMapper<AppInfo>{
int insertAppInfo(AppInfo appInfo);
List<AppInfo> getByPushId(int pushId);
AppInfo getById(String id);
}
|
[
"tuxw19900512@126.com"
] |
tuxw19900512@126.com
|
dc75a3de051b04aac928187b4e8c11d54e2975a3
|
571d1e0843beecd7f153b90ce71f93bcb7f91aae
|
/src/me/shufy/john/survival/crafting/recipes/john/JohnBoat.java
|
a98db903ebaab36e366f6fa5d438822d5d9f488f
|
[] |
no_license
|
Shmalah/Johnplug
|
1c34a0efd2c21ae9fc28df1009407017369695d7
|
00c4ffab0c7d324b91957926a2711a1a98cfaf59
|
refs/heads/master
| 2023-01-19T02:43:47.539343
| 2020-11-21T04:30:59
| 2020-11-21T04:30:59
| 309,054,583
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 790
|
java
|
package me.shufy.john.survival.crafting.recipes.john;
import me.shufy.john.survival.crafting.recipes.JohnCustomRecipe;
import me.shufy.john.survival.items.common.wood.JohnWood;
import org.bukkit.inventory.ItemStack;
public class JohnBoat extends JohnCustomRecipe {
@Override
public String getRecipeName() {
return "JohnBoat";
}
@Override
public ItemStack[] getRecipeMatrix() {
ItemStack johnWood = new JohnWood().getItemStack();
return new ItemStack[] {
null, null, null,
johnWood, null, johnWood,
johnWood, johnWood, johnWood
};
}
@Override
public ItemStack getRecipeResult() {
return new me.shufy.john.survival.items.stupid.boat.JohnBoat().getItemStack();
}
}
|
[
"unconfigured@null.spigotmc.org"
] |
unconfigured@null.spigotmc.org
|
3b184ab09bbdee7dbfe0984e8aa87346939817bc
|
7a21ff93edba001bef328a1e927699104bc046e5
|
/project-parent/module-parent/service-module-parent/revenue-service/src/main/java/com/dotop/smartwater/project/module/service/revenue/impl/DiscountConditionServiceImpl.java
|
01356fb2a2e5a74c56206079f62dbcceb5c1d6e3
|
[] |
no_license
|
150719873/zhdt
|
6ea1ca94b83e6db2012080f53060d4abaeaf12f5
|
c755dacdd76b71fd14aba5e475a5862a8d92c1f6
|
refs/heads/master
| 2022-12-16T06:59:28.373153
| 2020-09-14T06:57:16
| 2020-09-14T06:57:16
| 299,157,259
| 1
| 0
| null | 2020-09-28T01:45:10
| 2020-09-28T01:45:10
| null |
UTF-8
|
Java
| false
| false
| 4,495
|
java
|
package com.dotop.smartwater.project.module.service.revenue.impl;
import java.util.List;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.dao.DataAccessException;
import org.springframework.stereotype.Service;
import com.dotop.smartwater.dependence.core.exception.BaseExceptionConstants;
import com.dotop.smartwater.dependence.core.exception.FrameworkRuntimeException;
import com.dotop.smartwater.dependence.core.log.LogMsg;
import com.dotop.smartwater.dependence.core.pagination.Pagination;
import com.dotop.smartwater.dependence.core.utils.UuidUtils;
import com.dotop.smartwater.project.module.core.water.bo.ConditionBo;
import com.dotop.smartwater.project.module.core.water.dto.ConditionDto;
import com.dotop.smartwater.project.module.core.water.vo.ConditionVo;
import com.dotop.smartwater.project.module.dao.revenue.IDiscountConditionDao;
import com.dotop.smartwater.project.module.service.revenue.IDiscountConditionService;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
@Service
public class DiscountConditionServiceImpl implements IDiscountConditionService {
private static final Logger LOGGER = LogManager.getLogger(DiscountConditionServiceImpl.class);
@Autowired
private IDiscountConditionDao iDiscountConditionDao;
@Override
public void savecondition(ConditionBo conditionBo) {
try {
// 参数转换
ConditionDto conditionDto = new ConditionDto();
BeanUtils.copyProperties(conditionBo, conditionDto);
String id = UuidUtils.getUuid();
conditionDto.setId(id);
// 操作数据
iDiscountConditionDao.savecondition(conditionDto);
} catch (DataAccessException e) {
LOGGER.error(LogMsg.to(e));
throw new FrameworkRuntimeException(BaseExceptionConstants.DATABASE_EXCEPTION, e.getMessage(), e);
}
}
@Override
public void editcondition(ConditionBo conditionBo) {
try {
// 参数转换
ConditionDto conditionDto = new ConditionDto();
BeanUtils.copyProperties(conditionBo, conditionDto);
// 操作数据
iDiscountConditionDao.editcondition(conditionDto);
} catch (DataAccessException e) {
LOGGER.error(LogMsg.to(e));
throw new FrameworkRuntimeException(BaseExceptionConstants.DATABASE_EXCEPTION, e.getMessage(), e);
}
}
@Override
public ConditionVo getCondition(ConditionBo conditionBo) {
try {
// 参数转换
ConditionDto conditionDto = new ConditionDto();
BeanUtils.copyProperties(conditionBo, conditionDto);
// 操作数据
return iDiscountConditionDao.getCondition(conditionDto);
} catch (DataAccessException e) {
LOGGER.error(LogMsg.to(e));
throw new FrameworkRuntimeException(BaseExceptionConstants.DATABASE_EXCEPTION, e.getMessage(), e);
}
}
@Override
public void deleteCond(ConditionBo conditionBo) {
try {
// 参数转换
ConditionDto conditionDto = new ConditionDto();
BeanUtils.copyProperties(conditionBo, conditionDto);
// 操作数据
iDiscountConditionDao.deleteCond(conditionDto);
} catch (DataAccessException e) {
LOGGER.error(LogMsg.to(e));
throw new FrameworkRuntimeException(BaseExceptionConstants.DATABASE_EXCEPTION, e.getMessage(), e);
}
}
@Override
public Pagination<ConditionVo> findcondition(ConditionBo conditionBo) {
try {
// 参数转换
ConditionDto conditionDto = new ConditionDto();
BeanUtils.copyProperties(conditionBo, conditionDto);
// 操作数据
Page<Object> pageHelper = PageHelper.startPage(conditionBo.getPage(), conditionBo.getPageCount());
List<ConditionVo> list = iDiscountConditionDao.findcondition(conditionBo);
// 拼接数据返回
return new Pagination<>(conditionBo.getPage(), conditionBo.getPageCount(), list, pageHelper.getTotal());
} catch (DataAccessException e) {
LOGGER.error(LogMsg.to(e));
throw new FrameworkRuntimeException(BaseExceptionConstants.DATABASE_EXCEPTION, e.getMessage(), e);
}
}
@Override
public List<ConditionVo> getcondtions(ConditionBo conditionBo) {
try {
// 参数转换
ConditionDto conditionDto = new ConditionDto();
BeanUtils.copyProperties(conditionBo, conditionDto);
// 操作数据
return iDiscountConditionDao.getcondtions(conditionBo);
} catch (DataAccessException e) {
LOGGER.error(LogMsg.to(e));
throw new FrameworkRuntimeException(BaseExceptionConstants.DATABASE_EXCEPTION, e.getMessage(), e);
}
}
}
|
[
"2216502193@qq.com"
] |
2216502193@qq.com
|
ed0dfec27eee9eb8a217adc0db6e59be73d2c434
|
b55109e36f35eda6cb84bfbe67cf2f363ace235e
|
/Server/src/DataStub/AccountData_stub.java
|
c3ae00a3d3294e8b1010c014ffb6b235e0ce42d2
|
[] |
no_license
|
JonySheep/XiangXiangDeng
|
cb87e65e24080302f3f135e9e22f23735fe424d5
|
4ad25e3781d30050c5c7e0b29767e07477cae750
|
refs/heads/master
| 2021-04-30T12:18:09.803163
| 2018-02-12T16:51:37
| 2018-02-12T16:51:37
| 121,271,929
| 1
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 983
|
java
|
package DataStub;
import DataService.AccountDataService;
import PO.AccountPO;
import Util.ResultMessage;
import java.rmi.RemoteException;
import java.util.ArrayList;
/**
* Created by Administrator on 2017/10/23.
*/
public class AccountData_stub implements AccountDataService {
@Override
public ResultMessage disguiseDeleteAccount(String id) throws RemoteException {
return null;
}
@Override
public ResultMessage insert(AccountPO po) throws RemoteException {
return null;
}
@Override
public ResultMessage update(AccountPO po) throws RemoteException {
return null;
}
@Override
public AccountPO getInfo(String cardName) throws RemoteException {
return null;
}
@Override
public ArrayList<AccountPO> search(String str) throws RemoteException {
return null;
}
@Override
public ArrayList<AccountPO> getAllAccounts() throws RemoteException {
return null;
}
}
|
[
"161250180@mail.smal.nju.edu.cn"
] |
161250180@mail.smal.nju.edu.cn
|
074fa15d4ab55eb22072d7d7f5beccb152ae5531
|
c91d3c7a37572ad68009774682b6c35dc69215e3
|
/modules/core/src/test/java/org/lwjgl/demo/stb/Truetype.java
|
8a21aa5cf1bd984f9fcf1d4d11ced0354e433545
|
[] |
no_license
|
linghushaoxia/lwjgl3
|
669640d59836f36b0fa6bff74706e7f68a6b28f3
|
c4e1f9b035ffb7e9560b583c5edf5bc7765700e9
|
refs/heads/master
| 2020-12-31T03:03:41.535228
| 2015-07-06T17:44:55
| 2015-07-06T17:44:55
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,316
|
java
|
/*
* Copyright LWJGL. All rights reserved.
* License terms: http://lwjgl.org/license.php
*/
package org.lwjgl.demo.stb;
import org.lwjgl.BufferUtils;
import org.lwjgl.stb.STBTTAlignedQuad;
import org.lwjgl.stb.STBTTBakedChar;
import java.io.IOException;
import java.nio.ByteBuffer;
import java.nio.FloatBuffer;
import static org.lwjgl.demo.util.IOUtil.*;
import static org.lwjgl.glfw.GLFW.*;
import static org.lwjgl.opengl.GL11.*;
import static org.lwjgl.stb.STBTruetype.*;
/** STB Truetype demo. */
public final class Truetype extends FontDemo {
private Truetype(String filePath) {
super(24, filePath);
}
public static void main(String[] args) {
String filePath;
if ( args.length == 0 ) {
System.out.println("Use 'ant demo -Dclass=org.lwjgl.demo.stb.Truetype -Dargs=<path>' to load a different text file (must be UTF8-encoded).\n");
filePath = "demo/raytracing/hybrid.glsl";
} else
filePath = args[0];
new Truetype(filePath).run("STB Truetype Demo");
}
@Override
protected void loop() {
int BITMAP_W = 512;
int BITMAP_H = 512;
int texID = glGenTextures();
ByteBuffer cdata = BufferUtils.createByteBuffer(96 * STBTTBakedChar.SIZEOF);
try {
ByteBuffer ttf = ioResourceToByteBuffer("demo/FiraSans.ttf", 160 * 1024);
ByteBuffer bitmap = BufferUtils.createByteBuffer(BITMAP_W * BITMAP_H);
stbtt_BakeFontBitmap(ttf, getFontHeight(), bitmap, BITMAP_W, BITMAP_H, 32, cdata);
glBindTexture(GL_TEXTURE_2D, texID);
glTexImage2D(GL_TEXTURE_2D, 0, GL_ALPHA, BITMAP_W, BITMAP_H, 0, GL_ALPHA, GL_UNSIGNED_BYTE, bitmap);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
} catch (IOException e) {
throw new RuntimeException(e);
}
glClearColor(43f / 255f, 43f / 255f, 43f / 255f, 0f); // BG color
glColor3f(169f / 255f, 183f / 255f, 198f / 255f); // Text color
glEnable(GL_TEXTURE_2D);
glEnable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
FloatBuffer x = BufferUtils.createFloatBuffer(1);
FloatBuffer y = BufferUtils.createFloatBuffer(1);
STBTTAlignedQuad q = new STBTTAlignedQuad();
while ( glfwWindowShouldClose(getWindow()) == GL_FALSE ) {
glfwPollEvents();
glClear(GL_COLOR_BUFFER_BIT);
float scaleFactor = 1.0f + getScale() * 0.25f;
glPushMatrix();
// Zoom
glScalef(scaleFactor, scaleFactor, 1f);
// Scroll
glTranslatef(4.0f, getFontHeight() * 0.5f + 4.0f - getLineOffset() * getFontHeight(), 0f);
x.put(0, 0.0f);
y.put(0, 0.0f);
glBegin(GL_QUADS);
for ( int i = 0; i < text.length(); i++ ) {
char c = text.charAt(i);
if ( c == '\n' ) {
y.put(0, y.get(0) + getFontHeight());
x.put(0, 0.0f);
continue;
} else if ( c < 32 || 128 <= c )
continue;
stbtt_GetBakedQuad(cdata, BITMAP_W, BITMAP_H, c - 32, x, y, q.buffer(), 1);
glTexCoord2f(q.getS0(), q.getT0());
glVertex2f(q.getX0(), q.getY0());
glTexCoord2f(q.getS1(), q.getT0());
glVertex2f(q.getX1(), q.getY0());
glTexCoord2f(q.getS1(), q.getT1());
glVertex2f(q.getX1(), q.getY1());
glTexCoord2f(q.getS0(), q.getT1());
glVertex2f(q.getX0(), q.getY1());
}
glEnd();
glPopMatrix();
glfwSwapBuffers(getWindow());
}
glfwDestroyWindow(getWindow());
}
}
|
[
"iotsakp@gmail.com"
] |
iotsakp@gmail.com
|
a599fc8a2108234b46f6a322552a5a6f409a7f2c
|
32072bf80206f033f3a65f77d26d86c0478315a9
|
/src/main/java/org/kyojo/schemaOrg/m3n3/doma/healthLifesci/clazz/ImagingTestConverter.java
|
149c49113790dcdd2ca4947a1e5ff7078259f262
|
[
"Apache-2.0"
] |
permissive
|
covernorgedi/nagoyakaICT
|
76613d014dc70479f4b4364e51e7ba002ba1f5af
|
b375db53216eaa54f9797549a36e7c79f66b44c0
|
refs/heads/master
| 2021-04-09T14:21:23.670598
| 2018-03-20T10:43:37
| 2018-03-20T10:43:37
| 125,742,242
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 593
|
java
|
package org.kyojo.schemaOrg.m3n3.doma.healthLifesci.clazz;
import org.seasar.doma.ExternalDomain;
import org.seasar.doma.jdbc.domain.DomainConverter;
import org.kyojo.schemaOrg.m3n3.healthLifesci.impl.IMAGING_TEST;
import org.kyojo.schemaOrg.m3n3.healthLifesci.Clazz.ImagingTest;
@ExternalDomain
public class ImagingTestConverter implements DomainConverter<ImagingTest, String> {
@Override
public String fromDomainToValue(ImagingTest domain) {
return domain.getNativeValue();
}
@Override
public ImagingTest fromValueToDomain(String value) {
return new IMAGING_TEST(value);
}
}
|
[
"covernorgedi@icloud.com"
] |
covernorgedi@icloud.com
|
d7ca6d8b8ea446a580f68f6fbc861f338f0f62b5
|
fa91450deb625cda070e82d5c31770be5ca1dec6
|
/Diff-Raw-Data/30/30_496cc6b332300dbd255ca3dab01e5b8684b05335/ImportDeck/30_496cc6b332300dbd255ca3dab01e5b8684b05335_ImportDeck_t.java
|
347875c4a255287bfbaa176693dc56c036537507
|
[] |
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,127
|
java
|
/* memory
* de.thm.ateam.memory.engine.type
* ImportDeck.java
* 26.07.2012
*
* by Frank Kevin Zey
*/
package de.thm.ateam.memory.engine.type;
import java.io.IOException;
import java.io.InputStream;
import java.util.ArrayList;
import java.util.Enumeration;
import java.util.zip.ZipEntry;
import java.util.zip.ZipFile;
import de.thm.ateam.memory.engine.MemoryDeckDAO;
import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.os.Looper;
import android.util.Log;
import android.widget.Toast;
/**
* @author Frank Kevin Zey
*
*/
public class ImportDeck extends Deck implements Runnable {
private ZipFile z;
private Context c;
public ImportDeck(Context ctx, ZipFile zip) {
this.z = zip;
this.c = ctx;
}
/* (non-Javadoc)
* @see java.lang.Runnable#run()
*/
public void run() {
Looper.prepare();
Enumeration<? extends ZipEntry> e = z.entries();
frontSide = new ArrayList<Bitmap>();
while(e.hasMoreElements()) {
ZipEntry entry = e.nextElement();
InputStream f;
try {
f = z.getInputStream(entry);
byte[] b = new byte[(int)f.available()];
f.read(b,0,b.length);
Bitmap bm = BitmapFactory.decodeByteArray(b, 0, b.length);
if (entry.getName().equals("0.jpg"))
backSide = bm;
else
frontSide.add(bm);
Log.i(TAG,entry.getName());
} catch (IOException e1) {
Toast.makeText(c, "import failed", Toast.LENGTH_SHORT);
return;
}
}
String[] tmp = z.getName().split("/");
if (backSide == null || frontSide == null || frontSide.size() < 32) {
Toast.makeText(c, "not enough images", Toast.LENGTH_LONG);
return;
}
this.name = tmp[tmp.length-1].substring(0, tmp[tmp.length-1].length() - 4);
dao = new MemoryDeckDAO(c);
if (dao.storeDeck(this))
Log.i(TAG, "stored");
else
Log.i(TAG, "not stored");
try {
z.close();
} catch (IOException e1) {
}
}
}
|
[
"yuzhongxing88@gmail.com"
] |
yuzhongxing88@gmail.com
|
85a7350bf7074cdecf6d8de9afee90f37e632764
|
6e164456d9de44684b008f500bdaace786e3ddac
|
/app/src/main/java/com/lubanjianye/biaoxuntong/app/MainFragment.java
|
b559e58789e07862b967eb422adfbad3140bc465
|
[] |
no_license
|
lunious/AppFrame
|
4bdd62cbe7089d22d8828a92ac2c332468fcfc67
|
892cc3147ddb1404b9ec0636f1596e3aa0511e88
|
refs/heads/master
| 2021-08-24T09:48:06.879291
| 2017-12-09T03:43:05
| 2017-12-09T03:43:05
| 113,639,223
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,930
|
java
|
package com.lubanjianye.biaoxuntong.app;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.lubanjianye.biaoxuntong.R;
import com.lubanjianye.biaoxuntong.event.TabSelectedEvent;
import com.lubanjianye.biaoxuntong.ui.fragment.first.FirstTabFragment;
import com.lubanjianye.biaoxuntong.ui.fragment.five.FiveTabFragment;
import com.lubanjianye.biaoxuntong.ui.fragment.four.FourTabFragment;
import com.lubanjianye.biaoxuntong.ui.fragment.second.SecondTabFragment;
import com.lubanjianye.biaoxuntong.ui.fragment.third.ThirdTabFragment;
import com.lubanjianye.biaoxuntong.ui.view.botton.BottomBar;
import com.lubanjianye.biaoxuntong.ui.view.botton.BottomBarTab;
import me.yokeyword.eventbusactivityscope.EventBusActivityScope;
import me.yokeyword.fragmentation.SupportFragment;
/**
* 项目名: AppLunious
* 包名: com.lubanjianye.biaoxuntong.app
* 文件名: MainFragment
* 创建者: lunious
* 创建时间: 2017/12/9 0:13
* 描述: TODO
*/
public class MainFragment extends SupportFragment {
public static final int FIRST = 0;
public static final int SECOND = 1;
public static final int THIRD = 2;
public static final int FOUR = 3;
public static final int FIVE = 4;
private SupportFragment[] mFragments = new SupportFragment[5];
private BottomBar mBottomBar;
public static MainFragment newInstance() {
Bundle args = new Bundle();
MainFragment fragment = new MainFragment();
fragment.setArguments(args);
return fragment;
}
@Nullable
@Override
public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
View view = inflater.inflate(R.layout.fragment_main, container, false);
initView(view);
return view;
}
@Override
public void onActivityCreated(@Nullable Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
SupportFragment firstFragment = findChildFragment(FirstTabFragment.class);
if (firstFragment == null) {
mFragments[FIRST] = FirstTabFragment.newInstance();
mFragments[SECOND] = SecondTabFragment.newInstance();
mFragments[THIRD] = ThirdTabFragment.newInstance();
mFragments[FOUR] = FourTabFragment.newInstance();
mFragments[FIVE] = FiveTabFragment.newInstance();
loadMultipleRootFragment(R.id.fl_tab_container, FIRST,
mFragments[FIRST],
mFragments[SECOND],
mFragments[THIRD],
mFragments[FOUR],
mFragments[FIVE]);
} else {
// 这里库已经做了Fragment恢复,所有不需要额外的处理了, 不会出现重叠问题
// 这里我们需要拿到mFragments的引用
mFragments[FIRST] = firstFragment;
mFragments[SECOND] = findChildFragment(SecondTabFragment.class);
mFragments[THIRD] = findChildFragment(ThirdTabFragment.class);
mFragments[FOUR] = findChildFragment(FourTabFragment.class);
mFragments[FIVE] = findChildFragment(FiveTabFragment.class);
}
}
private void initView(View view) {
mBottomBar = (BottomBar) view.findViewById(R.id.bottomBar);
mBottomBar
.addItem(new BottomBarTab(_mActivity, R.mipmap.ic_launcher, getString(R.string.first)))
.addItem(new BottomBarTab(_mActivity, R.mipmap.ic_launcher, getString(R.string.second)))
.addItem(new BottomBarTab(_mActivity, R.mipmap.ic_launcher, getString(R.string.third)))
.addItem(new BottomBarTab(_mActivity, R.mipmap.ic_launcher, getString(R.string.four)))
.addItem(new BottomBarTab(_mActivity, R.mipmap.ic_launcher, getString(R.string.five)));
mBottomBar.setOnTabSelectedListener(new BottomBar.OnTabSelectedListener() {
@Override
public void onTabSelected(int position, int prePosition) {
showHideFragment(mFragments[position], mFragments[prePosition]);
}
@Override
public void onTabUnselected(int position) {
}
@Override
public void onTabReselected(int position) {
// 在FirstPagerFragment,FirstHomeFragment中接收, 因为是嵌套的Fragment
// 主要为了交互: 重选tab 如果列表不在顶部则移动到顶部,如果已经在顶部,则刷新
EventBusActivityScope.getDefault(_mActivity).post(new TabSelectedEvent(position));
}
});
}
/**
* start other BrotherFragment
*/
public void startBrotherFragment(SupportFragment targetFragment) {
start(targetFragment);
}
}
|
[
"1164503275@qq.com"
] |
1164503275@qq.com
|
cdf4435ed7c609645e71fa8e8a593facc846ad67
|
9bfa71d23e70e514dd9be5f47781b1178833130d
|
/SQLPlugin/gen/com/sqlplugin/psi/impl/SqlRegularCharacterSetIdentifierImpl.java
|
ea5462f59b95b337717ce6c08c789c092807626d
|
[
"MIT"
] |
permissive
|
smoothwind/SQL-IDEAplugin
|
de341884b77c2c61e0b4d6ceefd7c16ff3b7b469
|
3efa434095b4cac4772a0a7df18b34042a4c7557
|
refs/heads/master
| 2020-04-16T22:37:44.776363
| 2019-01-28T09:43:25
| 2019-01-28T09:43:25
| 165,976,439
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| true
| 1,057
|
java
|
// This is a generated file. Not intended for manual editing.
package com.sqlplugin.psi.impl;
import java.util.List;
import org.jetbrains.annotations.*;
import com.intellij.lang.ASTNode;
import com.intellij.psi.PsiElement;
import com.intellij.psi.PsiElementVisitor;
import com.intellij.psi.util.PsiTreeUtil;
import static com.sqlplugin.psi.SqlTypes.*;
import com.intellij.extapi.psi.ASTWrapperPsiElement;
import com.sqlplugin.psi.*;
public class SqlRegularCharacterSetIdentifierImpl extends ASTWrapperPsiElement implements SqlRegularCharacterSetIdentifier {
public SqlRegularCharacterSetIdentifierImpl(@NotNull ASTNode node) {
super(node);
}
public void accept(@NotNull SqlVisitor visitor) {
visitor.visitRegularCharacterSetIdentifier(this);
}
public void accept(@NotNull PsiElementVisitor visitor) {
if (visitor instanceof SqlVisitor) accept((SqlVisitor)visitor);
else super.accept(visitor);
}
@Override
@NotNull
public SqlIdentifier getIdentifier() {
return findNotNullChildByClass(SqlIdentifier.class);
}
}
|
[
"stephen.idle@qq.com"
] |
stephen.idle@qq.com
|
20aaf57e9a77e00f084dd9593c2d8c16adab08be
|
a4f94f4701a59cafc7407aed2d525b2dff985c95
|
/core/languageDesign/smodel/source_gen/jetbrains/mps/lang/smodel/behavior/SNodeTypeCastExpression_Behavior.java
|
911c71cb6939cc6a8103629625cec1999ecbedd3
|
[] |
no_license
|
jamice/code-orchestra-core
|
ffda62860f5b117386aa6455f4fdf61661abbe9e
|
b2bbf8362be2e2173864c294c635badb2e27ecc6
|
refs/heads/master
| 2021-01-15T13:24:53.517854
| 2013-05-09T21:39:28
| 2013-05-09T21:39:28
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,864
|
java
|
package jetbrains.mps.lang.smodel.behavior;
/*Generated by MPS */
import jetbrains.mps.smodel.SNode;
import jetbrains.mps.typesystem.inference.TypeChecker;
import jetbrains.mps.lang.smodel.generator.smodelAdapter.SLinkOperations;
import jetbrains.mps.lang.smodel.generator.smodelAdapter.SNodeOperations;
import jetbrains.mps.lang.smodel.generator.smodelAdapter.SPropertyOperations;
import jetbrains.mps.smodel.structure.BehaviorDescriptor;
import jetbrains.mps.smodel.structure.ConceptRegistry;
import jetbrains.mps.smodel.behaviour.BehaviorManager;
import java.util.Set;
import java.util.HashSet;
import jetbrains.mps.smodel.SModelUtil_new;
import jetbrains.mps.project.GlobalScope;
public class SNodeTypeCastExpression_Behavior {
private static Class[] PARAMETERS_2749027262099690841 = {SNode.class};
public static void init(SNode thisNode) {
}
public static boolean call_isSNodeCast_1238686302573(SNode thisNode) {
SNode leftType = TypeChecker.getInstance().getTypeOf(SLinkOperations.getTarget(thisNode, "leftExpression", true));
return !(TypeChecker.getInstance().getSubtypingManager().isSubtype(leftType, new SNodeTypeCastExpression_Behavior.QuotationClass_cjhknp_a1a0a0b0b().createNode(), false)) || SNodeOperations.isInstanceOf(leftType, "jetbrains.mps.lang.smodel.structure.SNodeType");
}
public static String virtual_getPresentation_1213877396640(SNode thisNode) {
return (SPropertyOperations.getBoolean(thisNode, "asCast") ?
"as" :
":"
);
}
public static String call_getPresentation_2749027262099690841(SNode thisNode) {
BehaviorDescriptor descriptor = ConceptRegistry.getInstance().getBehaviorDescriptorForInstanceNode(thisNode);
return (String) descriptor.invoke(Object.class, SNodeOperations.cast(thisNode, "jetbrains.mps.lang.smodel.structure.SNodeTypeCastExpression"), "virtual_getPresentation_1213877396640", PARAMETERS_2749027262099690841);
}
public static String callSuper_getPresentation_2749027262099690841(SNode thisNode, String callerConceptFqName) {
return (String) BehaviorManager.getInstance().invokeSuper(Object.class, SNodeOperations.cast(thisNode, "jetbrains.mps.lang.smodel.structure.SNodeTypeCastExpression"), callerConceptFqName, "virtual_getPresentation_1213877396640", PARAMETERS_2749027262099690841);
}
public static class QuotationClass_cjhknp_a1a0a0b0b {
public QuotationClass_cjhknp_a1a0a0b0b() {
}
public SNode createNode() {
SNode result = null;
Set<SNode> _parameterValues_129834374 = new HashSet<SNode>();
SNode quotedNode_1 = null;
{
quotedNode_1 = SModelUtil_new.instantiateConceptDeclaration("jetbrains.mps.lang.smodel.structure.SConceptType", null, GlobalScope.getInstance(), false);
SNode quotedNode1_2 = quotedNode_1;
result = quotedNode1_2;
}
return result;
}
}
}
|
[
"a.a.eliseyev@gmail.com"
] |
a.a.eliseyev@gmail.com
|
935615c5cfd58850ad0b8d9046d1799bbcec3144
|
f1155b8c40bfeb63e9aa5b0afc9e1e69c56ba766
|
/src/main/java/org/bian/dto/SDLeasingActivateOutputModelLeasingServiceConfigurationRecord.java
|
1e306c1b633887a7373c89c2a0293d860606fd0b
|
[
"Apache-2.0"
] |
permissive
|
bianapis/sd-leasing-v3
|
baa5c9d5160742cafd71e2dfc0976f7070901ac4
|
e21785ac1435397f45badcdd794fd06faf534ab4
|
refs/heads/master
| 2022-12-23T15:06:26.757751
| 2020-09-29T04:13:44
| 2020-09-29T04:13:44
| 298,787,436
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,560
|
java
|
package org.bian.dto;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import org.bian.dto.SDLeasingActivateInputModelLeasingServiceConfigurationRecordLeasingServiceConfigurationSetup;
import org.bian.dto.SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceAgreement;
import org.bian.dto.SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceSubscription;
import javax.validation.Valid;
/**
* SDLeasingActivateOutputModelLeasingServiceConfigurationRecord
*/
public class SDLeasingActivateOutputModelLeasingServiceConfigurationRecord {
private String leasingServiceConfigurationSettingReference = null;
private String leasingServiceConfigurationSettingDescription = null;
private SDLeasingActivateInputModelLeasingServiceConfigurationRecordLeasingServiceConfigurationSetup leasingServiceConfigurationSetup = null;
private SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceSubscription leasingServiceSubscription = null;
private SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceAgreement leasingServiceAgreement = null;
private String leasingServiceStatus = null;
/**
* `status: Not Mapped` core-data-type-reference: BIAN::DataTypesLibrary::CoreDataTypes::ISO20022andUNCEFACT::Identifier general-info: Refers to the service configuration parameter for the service
* @return leasingServiceConfigurationSettingReference
**/
public String getLeasingServiceConfigurationSettingReference() {
return leasingServiceConfigurationSettingReference;
}
public void setLeasingServiceConfigurationSettingReference(String leasingServiceConfigurationSettingReference) {
this.leasingServiceConfigurationSettingReference = leasingServiceConfigurationSettingReference;
}
/**
* `status: Not Mapped` core-data-type-reference: BIAN::DataTypesLibrary::CoreDataTypes::UNCEFACT::Text general-info: Description of the configuration parameter, allowed values and processing impact
* @return leasingServiceConfigurationSettingDescription
**/
public String getLeasingServiceConfigurationSettingDescription() {
return leasingServiceConfigurationSettingDescription;
}
public void setLeasingServiceConfigurationSettingDescription(String leasingServiceConfigurationSettingDescription) {
this.leasingServiceConfigurationSettingDescription = leasingServiceConfigurationSettingDescription;
}
/**
* Get leasingServiceConfigurationSetup
* @return leasingServiceConfigurationSetup
**/
public SDLeasingActivateInputModelLeasingServiceConfigurationRecordLeasingServiceConfigurationSetup getLeasingServiceConfigurationSetup() {
return leasingServiceConfigurationSetup;
}
public void setLeasingServiceConfigurationSetup(SDLeasingActivateInputModelLeasingServiceConfigurationRecordLeasingServiceConfigurationSetup leasingServiceConfigurationSetup) {
this.leasingServiceConfigurationSetup = leasingServiceConfigurationSetup;
}
/**
* Get leasingServiceSubscription
* @return leasingServiceSubscription
**/
public SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceSubscription getLeasingServiceSubscription() {
return leasingServiceSubscription;
}
public void setLeasingServiceSubscription(SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceSubscription leasingServiceSubscription) {
this.leasingServiceSubscription = leasingServiceSubscription;
}
/**
* Get leasingServiceAgreement
* @return leasingServiceAgreement
**/
public SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceAgreement getLeasingServiceAgreement() {
return leasingServiceAgreement;
}
public void setLeasingServiceAgreement(SDLeasingActivateOutputModelLeasingServiceConfigurationRecordLeasingServiceAgreement leasingServiceAgreement) {
this.leasingServiceAgreement = leasingServiceAgreement;
}
/**
* `status: Not Mapped` core-data-type-reference: BIAN::DataTypesLibrary::CoreDataTypes::UNCEFACT::Text general-info: The status of the offered service (e.g. active, suspended, idle)
* @return leasingServiceStatus
**/
public String getLeasingServiceStatus() {
return leasingServiceStatus;
}
public void setLeasingServiceStatus(String leasingServiceStatus) {
this.leasingServiceStatus = leasingServiceStatus;
}
}
|
[
"spabandara@Virtusa.com"
] |
spabandara@Virtusa.com
|
ed27ca80e2775e75e3c158711670aa7f693b3bfa
|
8496d1e3b6d02dabe838c8822daaa176f48faae5
|
/src/main/java/com/atguigu/design/proxy/dynamic/ITeacherDao.java
|
fadca06c66fb7dba2b9d9edbd9e4bccedad9f912
|
[] |
no_license
|
lgfy1984/JavaDesignPattern
|
6de47cf9760dbd003982062acd28fa60c15bda03
|
406523d8c9a61ff6b10d90935c73ea0456112c60
|
refs/heads/master
| 2022-12-27T11:08:01.324531
| 2021-03-24T02:52:28
| 2021-03-24T02:52:28
| 201,383,023
| 0
| 0
| null | 2022-12-16T03:47:17
| 2019-08-09T03:34:37
|
Java
|
UTF-8
|
Java
| false
| false
| 146
|
java
|
package com.atguigu.design.proxy.dynamic;
//接口
public interface ITeacherDao {
void teach(); // 授课方法
void sayHello(String name);
}
|
[
"lgfy1984@gmail.com"
] |
lgfy1984@gmail.com
|
84e81feb2483b7583cccdd4e9e94d78cdc0ac3ff
|
bd6ecb98c629d7780363970cb20ba3b92d3199c1
|
/src/main/java/com/github/prbrios/documentofiscal/cte/CTeInfCteInfCTeNormInfModalFerrovTrafMutFerroEnvEnderFerro.java
|
f64cf48fd7fc2db33b266ae7eb30967b46553bc4
|
[] |
no_license
|
prbrios/leiaute-documento-fiscal
|
5d4468c57f8abdfe0c47115fc3316b14a0961960
|
f1d67ef090c89ada318741ecd023d3a0680dcd27
|
refs/heads/master
| 2023-08-26T11:12:12.983779
| 2023-07-14T13:16:39
| 2023-07-14T13:16:39
| 212,176,018
| 0
| 0
| null | 2022-11-16T00:56:35
| 2019-10-01T18:57:21
|
Java
|
UTF-8
|
Java
| false
| false
| 1,589
|
java
|
package com.github.prbrios.documentofiscal.cte;
import org.simpleframework.xml.Element;
import org.simpleframework.xml.Root;
@Root(name = "enderFerro")
public class CTeInfCteInfCTeNormInfModalFerrovTrafMutFerroEnvEnderFerro {
@Element(name = "xLgr", required = false)
private String xLgr;
@Element(name = "nro", required = false)
private String nro;
@Element(name = "xCpl", required = false)
private String xCpl;
@Element(name = "xBairro", required = false)
private String xBairro;
@Element(name = "cMun", required = false)
private String cMun;
@Element(name = "xMun", required = false)
private String xMun;
@Element(name = "CEP", required = false)
private String CEP;
@Element(name = "UF", required = false)
private String UF;
public String getxLgr() {
return xLgr;
}
public void setxLgr(String xLgr) {
this.xLgr = xLgr;
}
public String getNro() {
return nro;
}
public void setNro(String nro) {
this.nro = nro;
}
public String getxCpl() {
return xCpl;
}
public void setxCpl(String xCpl) {
this.xCpl = xCpl;
}
public String getxBairro() {
return xBairro;
}
public void setxBairro(String xBairro) {
this.xBairro = xBairro;
}
public String getcMun() {
return cMun;
}
public void setcMun(String cMun) {
this.cMun = cMun;
}
public String getxMun() {
return xMun;
}
public void setxMun(String xMun) {
this.xMun = xMun;
}
public String getCEP() {
return CEP;
}
public void setCEP(String cEP) {
CEP = cEP;
}
public String getUF() {
return UF;
}
public void setUF(String uF) {
UF = uF;
}
}
|
[
"prbrios@gmail.com"
] |
prbrios@gmail.com
|
c0c647fbed95e5ef7ae6af2566d798ac5d7b8be1
|
60207b4b7201f34f3ba96fdf4747b968008109ef
|
/app/src/main/java/com/example/pproject/model/dto/ReserveThemeRespDto.java
|
a750f7f475dc5734d7a4ae50b54b185d2948746e
|
[] |
no_license
|
garasaja/android_finalproject
|
dc0aa8b6b7490dbe4cfe2a2b16f350271d854e2d
|
789ca69e66ad941646b0f7624642394773afaa13
|
refs/heads/master
| 2022-12-23T22:45:40.474213
| 2020-10-01T14:34:18
| 2020-10-01T14:34:18
| 283,254,618
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 288
|
java
|
package com.example.pproject.model.dto;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class ReserveThemeRespDto {
private int id;
private String name;
}
|
[
"cokj1610@naver.com"
] |
cokj1610@naver.com
|
2fbf923d6e0698d52ec3578caa6367cbd6bdde48
|
124df74bce796598d224c4380c60c8e95756f761
|
/hydro/ohd.ihfsdb/src/ohd/hseb/ihfsdb/generated/RWBiasDynRecord.java
|
6a5cd49da1b6c3b60553684b45f153b93a8e3362
|
[] |
no_license
|
Mapoet/AWIPS-Test
|
19059bbd401573950995c8cc442ddd45588e6c9f
|
43c5a7cc360b3cbec2ae94cb58594fe247253621
|
refs/heads/master
| 2020-04-17T03:35:57.762513
| 2017-02-06T17:17:58
| 2017-02-06T17:17:58
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 4,271
|
java
|
// filename: RWBiasDynRecord.java
// author : DBGEN
// created : Tue May 31 17:52:17 CDT 2011 using database hd_ob83oax
// description: This class is used to get data from and put data into a
// RWBiasDyn table record format
//
package ohd.hseb.ihfsdb.generated;
import ohd.hseb.db.*;
public class RWBiasDynRecord extends DbRecord
{
private String radid;
private String office_id;
private long obstime;
private short memspan_ind;
private double numpairs;
private float sumgag;
private float sumrad;
private float bias;
//---------------------------------------------------------------
// Empty constructor
//---------------------------------------------------------------
public RWBiasDynRecord()
{
}
//-----------------------------------------------------------------
// Copy constructor
//-----------------------------------------------------------------
public RWBiasDynRecord(RWBiasDynRecord origRecord)
{
setRadid(origRecord.getRadid());
setOffice_id(origRecord.getOffice_id());
setObstime(origRecord.getObstime());
setMemspan_ind(origRecord.getMemspan_ind());
setNumpairs(origRecord.getNumpairs());
setSumgag(origRecord.getSumgag());
setSumrad(origRecord.getSumrad());
setBias(origRecord.getBias());
}
//-----------------------------------------------------------------
// get and set methods for all data items in a RWBiasDyn record
//-----------------------------------------------------------------
public String getRadid()
{
return radid;
}
public void setRadid(String radid)
{
this.radid = radid ;
}
public String getOffice_id()
{
return office_id;
}
public void setOffice_id(String office_id)
{
this.office_id = office_id ;
}
public long getObstime()
{
return obstime;
}
public void setObstime(long obstime)
{
this.obstime = obstime ;
}
public short getMemspan_ind()
{
return memspan_ind;
}
public void setMemspan_ind(short memspan_ind)
{
this.memspan_ind = memspan_ind ;
}
public double getNumpairs()
{
return numpairs;
}
public void setNumpairs(double numpairs)
{
this.numpairs = numpairs ;
}
public float getSumgag()
{
return sumgag;
}
public void setSumgag(float sumgag)
{
this.sumgag = sumgag ;
}
public float getSumrad()
{
return sumrad;
}
public void setSumrad(float sumrad)
{
this.sumrad = sumrad ;
}
public float getBias()
{
return bias;
}
public void setBias(float bias)
{
this.bias = bias ;
}
//-----------------------------------------------------------------
// getWhereString() - this method is called with no arguments
// and returns a String that contains a valid where clause containing all the
// primary key fields.
//-----------------------------------------------------------------
public String getWhereString()
{
String outString =
"WHERE radid = '" + radid + "'"
+ " AND office_id = '" + office_id + "'"
+ " AND obstime = '" + getDateTimeStringFromLongTime(obstime) + "'"
+ " AND memspan_ind = '" + memspan_ind + "'"
;
return outString;
} // end toString()
//-----------------------------------------------------------------
// toString() - this method is called with no arguments
// and returns a String of the internal values
//-----------------------------------------------------------------
public String toString()
{
String outString =
getRadid() + " " +
getOffice_id() + " " +
getDateTimeStringFromLongTime(getObstime()) + " " +
getMemspan_ind() + " " +
getNumpairs() + " " +
getSumgag() + " " +
getSumrad() + " " +
getBias() + " " +
"" ;
return outString;
} // end toString()
} // end of RWBiasDynRecord class
|
[
"joshua.t.love@saic.com"
] |
joshua.t.love@saic.com
|
61b68e74b06cd3105e7ec73ca176a187e0dcfd9e
|
7016cec54fb7140fd93ed805514b74201f721ccd
|
/ui/web/main/src/java/com/echothree/ui/web/main/action/humanresources/employeealias/DeleteAction.java
|
3c5ee8f8c8b9b12ff94fcebdd09912167523133d
|
[
"MIT",
"Apache-1.1",
"Apache-2.0"
] |
permissive
|
echothreellc/echothree
|
62fa6e88ef6449406d3035de7642ed92ffb2831b
|
bfe6152b1a40075ec65af0880dda135350a50eaf
|
refs/heads/master
| 2023-09-01T08:58:01.429249
| 2023-08-21T11:44:08
| 2023-08-21T11:44:08
| 154,900,256
| 5
| 1
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 3,726
|
java
|
// --------------------------------------------------------------------------------
// Copyright 2002-2023 Echo Three, LLC
//
// 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.echothree.ui.web.main.action.humanresources.employeealias;
import com.echothree.control.user.party.common.PartyUtil;
import com.echothree.control.user.party.common.form.DeletePartyAliasForm;
import com.echothree.model.control.core.common.EntityTypes;
import com.echothree.ui.web.main.framework.MainBaseDeleteAction;
import com.echothree.ui.web.main.framework.ParameterConstants;
import com.echothree.util.common.command.CommandResult;
import com.echothree.view.client.web.struts.sprout.annotation.SproutAction;
import com.echothree.view.client.web.struts.sprout.annotation.SproutForward;
import com.echothree.view.client.web.struts.sprout.annotation.SproutProperty;
import com.echothree.view.client.web.struts.sslext.config.SecureActionMapping;
import java.util.Map;
import javax.naming.NamingException;
import javax.servlet.http.HttpServletRequest;
@SproutAction(
path = "/HumanResources/EmployeeAlias/Delete",
mappingClass = SecureActionMapping.class,
name = "EmployeeAliasDelete",
properties = {
@SproutProperty(property = "secure", value = "true")
},
forwards = {
@SproutForward(name = "Display", path = "/action/HumanResources/EmployeeAlias/Main", redirect = true),
@SproutForward(name = "Form", path = "/humanresources/employeealias/delete.jsp")
}
)
public class DeleteAction
extends MainBaseDeleteAction<DeleteActionForm> {
@Override
public String getEntityTypeName() {
return EntityTypes.PartyAlias.name();
}
@Override
public void setupParameters(DeleteActionForm actionForm, HttpServletRequest request) {
actionForm.setPartyName(findParameter(request, ParameterConstants.PARTY_NAME, actionForm.getPartyName()));
actionForm.setPartyAliasTypeName(findParameter(request, ParameterConstants.PARTY_ALIAS_TYPE_NAME, actionForm.getPartyAliasTypeName()));
}
@Override
public void setupTransfer(DeleteActionForm actionForm, HttpServletRequest request)
throws NamingException {
EmployeeAliasUtil.getInstance().setupPartyAliasTransfer(request, actionForm.getPartyName(), actionForm.getPartyAliasTypeName());
EmployeeAliasUtil.getInstance().setupEmployee(request, actionForm.getPartyName());
}
@Override
public CommandResult doDelete(DeleteActionForm actionForm, HttpServletRequest request)
throws NamingException {
DeletePartyAliasForm commandForm = PartyUtil.getHome().getDeletePartyAliasForm();
commandForm.setPartyName(actionForm.getPartyName());
commandForm.setPartyAliasTypeName(actionForm.getPartyAliasTypeName());
return PartyUtil.getHome().deletePartyAlias(getUserVisitPK(request), commandForm);
}
@Override
public void setupForwardParameters(DeleteActionForm actionForm, Map<String, String> parameters) {
parameters.put(ParameterConstants.PARTY_NAME, actionForm.getPartyName());
}
}
|
[
"rich@echothree.com"
] |
rich@echothree.com
|
463847078690c4d30a23bef5caed84529a5b3782
|
505c9a3de3afc264c6e5286f02534c97491fe6ea
|
/platforms/android/src/vova/kluf/myHelloWorldApp/MainActivity.java
|
6df42e76d22182edb5becb135abd488a9dec50db
|
[] |
no_license
|
kluf/phonegap
|
8e1984ae9179d658e8b6f4ba5d595c53b4f4c3b1
|
1e33dfec0a6b8d3ed26eb0a9e1adae670d19048b
|
refs/heads/master
| 2021-01-23T23:03:41.052181
| 2017-02-25T11:05:29
| 2017-02-25T11:05:29
| 83,125,948
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,458
|
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 vova.kluf.myHelloWorldApp;
import android.os.Bundle;
import org.apache.cordova.*;
public class MainActivity extends CordovaActivity
{
@Override
public void onCreate(Bundle savedInstanceState)
{
super.onCreate(savedInstanceState);
// enable Cordova apps to be started in the background
Bundle extras = getIntent().getExtras();
if (extras != null && extras.getBoolean("cdvStartInBackground", false)) {
moveTaskToBack(true);
}
// Set by <content src="index.html" /> in config.xml
loadUrl(launchUrl);
}
}
|
[
"test@test.com"
] |
test@test.com
|
9b8b3b0281dbdda3bb2ec234375b739234e88885
|
2b7c587542ffb625c92ee0770ae1f164f327096a
|
/ch04/40-Linking-Streams/TestClass.java
|
97070c9c273eec894f73c1790877162364d5330f
|
[] |
no_license
|
Sabyh11/Java-SE8-OCP-Exam-1Z0-809
|
bf881ea0e218838820022bfe3f6ee078dc0fd6c8
|
52a7c81c840b76f4c149056c71b119b1e5c1e32b
|
refs/heads/master
| 2022-01-20T11:10:47.983033
| 2018-07-07T17:41:00
| 2018-07-07T17:41:00
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 554
|
java
|
import java.util.List;
import java.util.ArrayList;
import java.util.stream.Stream;
public class TestClass {
public static void main(String[] args) {
List<String> cats = new ArrayList<>();
cats.add("Annie");
cats.add("Ripley");
Stream<String> stream = cats.stream();
cats.add("KC");
System.out.println(stream.count());
System.out.println("- - - - - ");
String[] s = new String[3];
s[0] = "one";
s[1] = "two";
stream = Stream.of(s);
s[2] = "three";
stream.forEach(System.out::println);
}
}
|
[
"mercurylink@gmail.com"
] |
mercurylink@gmail.com
|
1ce0bd5bd0e786501aef46dec35519b7f65c1828
|
1eec888dd03a5170b1f6a1cf1110bded7ded584c
|
/app/src/main/java/com/xyoye/dandanplay/ui/activities/TrackerActivity.java
|
5d1e20f083fa2def1754e2ef7f872e107217a59f
|
[
"MIT"
] |
permissive
|
HarryHeights/DanDanPlayForAndroid
|
1e515242cc7070b25db789e9418dc6161f01a190
|
a25c397877591d2fd4af925f131c9e364adffba7
|
refs/heads/master
| 2020-05-28T03:50:11.590947
| 2019-05-27T09:00:47
| 2019-05-27T09:00:47
| 188,871,585
| 1
| 0
|
MIT
| 2019-05-27T15:51:24
| 2019-05-27T15:51:23
| null |
UTF-8
|
Java
| false
| false
| 7,197
|
java
|
package com.xyoye.dandanplay.ui.activities;
import android.support.annotation.NonNull;
import android.support.design.widget.FloatingActionButton;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.TextView;
import com.xyoye.dandanplay.R;
import com.xyoye.dandanplay.app.IApplication;
import com.xyoye.dandanplay.base.BaseMvcActivity;
import com.xyoye.dandanplay.base.BaseRvAdapter;
import com.xyoye.dandanplay.bean.TrackerBean;
import com.xyoye.dandanplay.ui.weight.dialog.AddTrackerDialog;
import com.xyoye.dandanplay.ui.weight.dialog.CommonDialog;
import com.xyoye.dandanplay.ui.weight.item.TrackerItem;
import com.xyoye.dandanplay.utils.TrackerManager;
import com.xyoye.dandanplay.utils.interf.AdapterItem;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import butterknife.BindView;
import butterknife.OnClick;
/**
* Created by xyoye on 2019/3/30.
*/
public class TrackerActivity extends BaseMvcActivity {
@BindView(R.id.toolbar_title)
TextView toolbarTitle;
@BindView(R.id.toolbar)
android.support.v7.widget.Toolbar toolbar;
@BindView(R.id.tracker_rv)
RecyclerView trackerRv;
@BindView(R.id.add_tracker_bt)
FloatingActionButton addTrackerBt;
private MenuItem menuHelpItem, menuDeleteItem, menuCancelItem;
private BaseRvAdapter<TrackerBean> trackerAdapter;
private List<TrackerBean> trackerList;
@Override
protected int initPageLayoutID() {
return R.layout.activity_tracker;
}
@Override
public void initPageView() {
setTitle("tracker管理");
trackerList = new ArrayList<>();
trackerAdapter = new BaseRvAdapter<TrackerBean>(trackerList) {
@NonNull
@Override
public AdapterItem<TrackerBean> onCreateItem(int viewType) {
return new TrackerItem(new TrackerItem.TrackerItemListener() {
@Override
public void onClick(int position, boolean isChecked) {
trackerList.get(position).setSelected(isChecked);
trackerAdapter.notifyItemChanged(position);
}
@Override
public void onLongClick(int position) {
for (TrackerBean trackerBean : trackerList){
trackerBean.setSelectType(true);
trackerBean.setSelected(false);
}
trackerList.get(position).setSelected(true);
trackerAdapter.notifyDataSetChanged();
setTitle("删除tracker");
menuCancelItem.setVisible(true);
menuDeleteItem.setVisible(true);
menuHelpItem.setVisible(false);
addTrackerBt.setVisibility(View.GONE);
}
});
}
};
trackerRv.setLayoutManager(new LinearLayoutManager(this, LinearLayoutManager.VERTICAL, false));
trackerRv.setItemViewCacheSize(10);
trackerRv.setAdapter(trackerAdapter);
updateTracker();
}
@Override
public void initPageViewListener() {
addTrackerBt.setOnLongClickListener(v -> {
new CommonDialog.Builder(TrackerActivity.this)
.setOkListener(dialog -> {
TrackerManager.resetTracker();
updateTracker();
})
.setAutoDismiss()
.build()
.show("恢复为弹弹提供的初始tracker?");
return true;
});
}
@OnClick(R.id.add_tracker_bt)
public void onViewClicked() {
AddTrackerDialog dialog = new AddTrackerDialog(this, R.style.Dialog, this::updateTracker);
dialog.show();
}
@Override
protected void onResume() {
super.onResume();
}
@Override
protected void onPause() {
super.onPause();
}
@Override
public boolean onOptionsItemSelected(MenuItem item) {
switch (item.getItemId()){
case android.R.id.home:
finish();
break;
case R.id.tracker_help:
new CommonDialog.Builder(TrackerActivity.this)
.hideCancel()
.setAutoDismiss()
.build()
.show(getResources().getString(R.string.what_is_tracker), "什么是tracker", "确定", "");
break;
case R.id.tracker_delete:
Iterator iterator = trackerList.iterator();
while (iterator.hasNext()){
TrackerBean trackerBean = (TrackerBean)iterator.next();
if (trackerBean.isSelected()){
IApplication.trackers.remove(trackerBean.getTracker());
iterator.remove();
}else {
trackerBean.setSelectType(false);
trackerBean.setSelected(false);
}
}
TrackerManager.deleteTracker();
trackerAdapter.notifyDataSetChanged();
setTitle("tracker管理");
menuCancelItem.setVisible(false);
menuDeleteItem.setVisible(false);
menuHelpItem.setVisible(true);
addTrackerBt.setVisibility(View.VISIBLE);
break;
case R.id.tracker_cancel:
for (TrackerBean trackerBean : trackerList){
trackerBean.setSelected(false);
trackerBean.setSelectType(false);
}
trackerAdapter.notifyDataSetChanged();
setTitle("tracker管理");
menuCancelItem.setVisible(false);
menuDeleteItem.setVisible(false);
menuHelpItem.setVisible(true);
addTrackerBt.setVisibility(View.VISIBLE);
break;
}
return super.onOptionsItemSelected(item);
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
getMenuInflater().inflate(R.menu.menu_tracker, menu);
menuHelpItem = menu.findItem(R.id.tracker_help);
menuDeleteItem = menu.findItem(R.id.tracker_delete);
menuCancelItem = menu.findItem(R.id.tracker_cancel);
menuHelpItem.setVisible(true);
menuDeleteItem.setVisible(false);
menuCancelItem.setVisible(false);
return super.onCreateOptionsMenu(menu);
}
private void updateTracker(){
trackerList.clear();
for (String tracker : IApplication.trackers){
TrackerBean trackerBean = new TrackerBean();
trackerBean.setSelected(false);
trackerBean.setSelectType(false);
trackerBean.setTracker(tracker);
trackerList.add(trackerBean);
}
trackerAdapter.notifyDataSetChanged();
}
}
|
[
"Aser1127CBM"
] |
Aser1127CBM
|
41eb3c40d15130d606354134ff018ebdd1e88d95
|
4b187352b226c9286945ea975f03690200b9d60d
|
/3.JavaMultithreading/src/com/javarush/task/task25/task2506/LoggingStateThread.java
|
d1a85d872463f97f187bc721fad5fc7ed3694f75
|
[] |
no_license
|
Artemsetko/JavaRushTasks
|
f5fb912627e74f157090988b1cd2e4a26bb1d067
|
9ebfd5319184778647ba986232fe28c2e836ba0f
|
refs/heads/master
| 2020-03-19T11:56:08.212683
| 2018-06-25T08:23:45
| 2018-06-25T08:23:45
| 136,482,702
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 572
|
java
|
package com.javarush.task.task25.task2506;
public class LoggingStateThread extends Thread {
private Thread target;
public LoggingStateThread(Thread target) {
this.target = target;
}
@Override
public void run() {
State state = null;
while (true) {
State stateNew = target.getState();
if (stateNew != state) {
state = stateNew;
System.out.println(state);
}
if (state == State.TERMINATED) {
break;
}
}
}
}
|
[
"setkoartem@gmail.com"
] |
setkoartem@gmail.com
|
9d069267c14d6363c3bf414e73fb3a00283f60de
|
15b260ccada93e20bb696ae19b14ec62e78ed023
|
/v2/src/main/java/com/alipay/api/domain/TbapiQueryAmountBizContent.java
|
3b2a5cabdfcae6c725ff620738cdcf579a32d81f
|
[
"Apache-2.0"
] |
permissive
|
alipay/alipay-sdk-java-all
|
df461d00ead2be06d834c37ab1befa110736b5ab
|
8cd1750da98ce62dbc931ed437f6101684fbb66a
|
refs/heads/master
| 2023-08-27T03:59:06.566567
| 2023-08-22T14:54:57
| 2023-08-22T14:54:57
| 132,569,986
| 470
| 207
|
Apache-2.0
| 2022-12-25T07:37:40
| 2018-05-08T07:19:22
|
Java
|
UTF-8
|
Java
| false
| false
| 1,359
|
java
|
package com.alipay.api.domain;
import java.util.List;
import com.alipay.api.AlipayObject;
import com.alipay.api.internal.mapping.ApiField;
import com.alipay.api.internal.mapping.ApiListField;
/**
* 吃呗额度查询请求数据结构
*
* @author auto create
* @since 1.0, 2020-03-27 16:16:14
*/
public class TbapiQueryAmountBizContent extends AlipayObject {
private static final long serialVersionUID = 2384663559841722792L;
/**
* 查询指定额度产品组
*/
@ApiField("amt_group")
private String amtGroup;
/**
* 查询指定额度产品码
*/
@ApiListField("amt_prods")
@ApiField("string")
private List<String> amtProds;
/**
* 请求来源
*/
@ApiField("request_from")
private String requestFrom;
/**
* 请求场景
*/
@ApiField("scene")
private String scene;
public String getAmtGroup() {
return this.amtGroup;
}
public void setAmtGroup(String amtGroup) {
this.amtGroup = amtGroup;
}
public List<String> getAmtProds() {
return this.amtProds;
}
public void setAmtProds(List<String> amtProds) {
this.amtProds = amtProds;
}
public String getRequestFrom() {
return this.requestFrom;
}
public void setRequestFrom(String requestFrom) {
this.requestFrom = requestFrom;
}
public String getScene() {
return this.scene;
}
public void setScene(String scene) {
this.scene = scene;
}
}
|
[
"auto-publish"
] |
auto-publish
|
bb5ed4ecc6b2d5d9273f4a225576eece866bf2f1
|
ab161dcbc79f1902dd7fdc6fd3899435f5927642
|
/src/main/java/com/buit/his/dic/request/DicGbsj01QueryReq.java
|
b3ef63583e1b315bec35fb9a9cd1bc0115278795
|
[] |
no_license
|
gfz1103/system
|
88d7feec0dd84a6c77524f579496520c56901681
|
b48533c6a5bafe49f22f57c92996dbf53a11a8c7
|
refs/heads/master
| 2023-06-27T15:18:51.885391
| 2021-07-16T09:38:16
| 2021-07-16T09:38:16
| 386,574,567
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 632
|
java
|
package com.buit.his.dic.request;
import com.buit.commons.PageQuery;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
/**
* 类名称:DicGbsj01<br>
* 类描述:标准数据主记录<br>
* @author 老花生
*/
@ApiModel(value="标准数据主记录")
public class DicGbsj01QueryReq extends PageQuery {
@ApiModelProperty(value = "首字母拼音或汉字或区间编码或五笔码")
private String condition;
public String getCondition() {
return condition;
}
public void setCondition(String condition) {
this.condition = condition;
}
}
|
[
"gongfangzhou"
] |
gongfangzhou
|
a3137b404cb6c94a446105e1f85e391e092cf43d
|
c041c9ab973ec4eff0248202fd07ea36861d013a
|
/components/camel-paxlogging/src/generated/java/org/apache/camel/component/paxlogging/PaxLoggingEndpointConfigurer.java
|
39a651c4c9c05388972b9b9f4b244c0afb919a5d
|
[
"Apache-2.0"
] |
permissive
|
mmelko/camel-karaf
|
10f9aa4b5df23434850bd7e545d1274bc6239434
|
7ef7e7393c219e2a8d4a11d61eb6294589fdf43d
|
refs/heads/master
| 2022-11-05T20:09:50.947361
| 2020-06-23T07:01:44
| 2020-06-23T07:01:44
| 274,861,064
| 0
| 0
|
Apache-2.0
| 2020-06-25T08:03:02
| 2020-06-25T08:03:01
| null |
UTF-8
|
Java
| false
| false
| 2,980
|
java
|
/* Generated by camel build tools - do NOT edit this file! */
package org.apache.camel.component.paxlogging;
import java.util.Map;
import org.apache.camel.CamelContext;
import org.apache.camel.spi.GeneratedPropertyConfigurer;
import org.apache.camel.spi.PropertyConfigurerGetter;
import org.apache.camel.util.CaseInsensitiveMap;
import org.apache.camel.support.component.PropertyConfigurerSupport;
/**
* Generated by camel build tools - do NOT edit this file!
*/
@SuppressWarnings("unchecked")
public class PaxLoggingEndpointConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer, PropertyConfigurerGetter {
@Override
public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) {
PaxLoggingEndpoint target = (PaxLoggingEndpoint) obj;
switch (ignoreCase ? name.toLowerCase() : name) {
case "basicpropertybinding":
case "basicPropertyBinding": target.setBasicPropertyBinding(property(camelContext, boolean.class, value)); return true;
case "bridgeerrorhandler":
case "bridgeErrorHandler": target.setBridgeErrorHandler(property(camelContext, boolean.class, value)); return true;
case "exceptionhandler":
case "exceptionHandler": target.setExceptionHandler(property(camelContext, org.apache.camel.spi.ExceptionHandler.class, value)); return true;
case "exchangepattern":
case "exchangePattern": target.setExchangePattern(property(camelContext, org.apache.camel.ExchangePattern.class, value)); return true;
case "synchronous": target.setSynchronous(property(camelContext, boolean.class, value)); return true;
default: return false;
}
}
@Override
public Map<String, Object> getAllOptions(Object target) {
Map<String, Object> answer = new CaseInsensitiveMap();
answer.put("basicPropertyBinding", boolean.class);
answer.put("bridgeErrorHandler", boolean.class);
answer.put("exceptionHandler", org.apache.camel.spi.ExceptionHandler.class);
answer.put("exchangePattern", org.apache.camel.ExchangePattern.class);
answer.put("synchronous", boolean.class);
return answer;
}
@Override
public Object getOptionValue(Object obj, String name, boolean ignoreCase) {
PaxLoggingEndpoint target = (PaxLoggingEndpoint) obj;
switch (ignoreCase ? name.toLowerCase() : name) {
case "basicpropertybinding":
case "basicPropertyBinding": return target.isBasicPropertyBinding();
case "bridgeerrorhandler":
case "bridgeErrorHandler": return target.isBridgeErrorHandler();
case "exceptionhandler":
case "exceptionHandler": return target.getExceptionHandler();
case "exchangepattern":
case "exchangePattern": return target.getExchangePattern();
case "synchronous": return target.isSynchronous();
default: return null;
}
}
}
|
[
"ancosen@gmail.com"
] |
ancosen@gmail.com
|
7277da17e7d29986eb9e21f7e649e79f062c5430
|
2f219b5a60919cb2ed92dfe4e147ad7dd40e42f9
|
/S14_Unit_Test_Login/src/controllers/CreateUserController.java
|
05f90a2eec1e6d6ca5c7d2ad0c8d9a80c3a03d59
|
[] |
no_license
|
KhaledHammoun/Second-semester
|
6a440027ff3cc4078b74f04c5878a9c7b74e8c61
|
d8d9628fa2de3d68933cfb5a12e83ba9fee5e551
|
refs/heads/main
| 2023-04-18T17:55:12.470383
| 2021-05-04T12:41:05
| 2021-05-04T12:41:05
| 337,375,515
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 2,546
|
java
|
package controllers;
import javafx.beans.Observable;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.scene.control.Label;
import javafx.scene.control.TextField;
import core.ViewHandler;
import viewmodels.CreateUserVM;
public class CreateUserController {
// setting up all the connections to various GUI elements: Text fields and labels.
// These are automatically set by the JavaFX framework.
// Notice the small icon to the left, indicating IntelliJ knows about the connection.
// If the Icon is not there, something is wrong
@FXML
private Label createResultLabel;
@FXML
private TextField passwordAgainTextField;
@FXML
private TextField passwordTextField;
@FXML
private TextField usernameTextField;
private CreateUserVM createUserVM;
private ViewHandler viewHandler;
public void init(CreateUserVM createUserVM, ViewHandler viewHandler) {
this.createUserVM = createUserVM;
this.viewHandler = viewHandler;
// setting up bindings
createResultLabel.textProperty().bind(createUserVM.createUserResultProperty());
// adding a listener, so when the value of the label changes, the method "onCreateUser" is called
createResultLabel.textProperty().addListener(this::onCreateUser);
// setting up bidirectional bindings, so data can flow automatically between controller and view model
usernameTextField.textProperty().bindBidirectional(createUserVM.usernameProperty());
passwordTextField.textProperty().bindBidirectional(createUserVM.passwordProperty());
passwordAgainTextField.textProperty().bindBidirectional(createUserVM.passwordAgainProperty());
}
// method called, when the content of the result label changes. This is changed from the View Model, based on the
// result of the Model.
// If all is okay, then I clear the fields, and open the login view, assuming the user has been created.
private void onCreateUser(Observable observable, String old, String newVal) {
if("OK".equals(newVal)) {
createUserVM.clearFields();
viewHandler.openLoginView();
}
}
// method called, when the create user button is pressed.
// make the View Model handle the request
public void onCreateUserButton(ActionEvent actionEvent) {
createUserVM.attemptCreateUser();
}
public void onCancelButton(ActionEvent actionEvent) {
createUserVM.clearFields();
viewHandler.openLoginView();
}
}
|
[
"kh.hammoun@gmail.com"
] |
kh.hammoun@gmail.com
|
479ce34f79b24609e3b646b807e2e87905cbbd56
|
4bb83687710716d91b5da55054c04f430474ee52
|
/dsrc/sku.0/sys.server/compiled/game/script/systems/combat/combat_supply_drop_controller.java
|
b8dd6c378f8109d8168f7fe2b32da4adb127e5ef
|
[] |
no_license
|
geralex/SWG-NGE
|
0846566a44f4460c32d38078e0a1eb115a9b08b0
|
fa8ae0017f996e400fccc5ba3763e5bb1c8cdd1c
|
refs/heads/master
| 2020-04-06T11:18:36.110302
| 2018-03-19T15:42:32
| 2018-03-19T15:42:32
| 157,411,938
| 1
| 0
| null | 2018-11-13T16:35:01
| 2018-11-13T16:35:01
| null |
UTF-8
|
Java
| false
| false
| 7,752
|
java
|
package script.systems.combat;
import script.*;
import script.base_class.*;
import script.combat_engine.*;
import java.util.Arrays;
import java.util.Hashtable;
import java.util.Vector;
import script.base_script;
import script.library.callable;
import script.library.static_item;
import script.library.utils;
import script.library.pet_lib;
import script.library.ai_lib;
import script.library.create;
import script.library.prose;
public class combat_supply_drop_controller extends script.base_script
{
public combat_supply_drop_controller()
{
}
public static final string_id SID_ACQUIRE_HIRELING = new string_id("spam", "officer_pet_success");
public static final string_id SID_TOO_MANY_HIRELINGS = new string_id("spam", "officer_too_many_pets");
public static final String FOOD_TABLE = "datatables/loot/officer_supply_drop.iff";
public static final String FOOD_LOW = "low";
public static final String FOOD_MID = "mid";
public static final String FOOD_HIGH = "high";
public static final int FOOD_ITEMS = 2;
public static final int GROUP_SIZE = 8;
public static final int LEVEL_LOW_CAP = 45;
public static final int LEVEL_MID_CAP = 75;
public int startLandingSequence(obj_id self, dictionary params) throws InterruptedException
{
obj_id owner = params.getObjId("owner");
int supplyId = params.getInt("supplyId");
queueCommand(self, (-1114832209), self, "", COMMAND_PRIORITY_FRONT);
setPosture(self, POSTURE_PRONE);
dictionary d = new dictionary();
d.put("owner", owner);
d.put("supplyId", supplyId);
if (supplyId < 13)
{
messageTo(self, "dropSupplies", d, 22.0f, false);
}
else
{
messageTo(self, "dropReinforcements", d, 22.0f, false);
}
return SCRIPT_CONTINUE;
}
public int dropReinforcements(obj_id self, dictionary params) throws InterruptedException
{
obj_id owner = params.getObjId("owner");
int supplyId = params.getInt("supplyId");
location loc = getLocation(self);
String itemString = "";
switch (supplyId)
{
case 13:
itemString = "officer_reinforcement_1";
break;
case 14:
itemString = "officer_reinforcement_2";
break;
case 15:
itemString = "officer_reinforcement_3";
break;
case 16:
itemString = "officer_reinforcement_4";
break;
case 17:
itemString = "officer_reinforcement_5";
break;
}
if (supplyId > 12 && supplyId <= 17 && (itemString != null || !itemString.equals("")))
{
summonOfficerPet(owner, itemString, loc);
}
dictionary d = new dictionary();
d.put("owner", owner);
messageTo(self, "startTakeOffSequence", d, 2.0f, false);
return SCRIPT_CONTINUE;
}
public int dropSupplies(obj_id self, dictionary params) throws InterruptedException
{
obj_id owner = params.getObjId("owner");
int supplyId = params.getInt("supplyId");
int level = getLevel(owner);
location loc = getLocation(self);
obj_id crate = createObject("object/tangible/container/drum/supply_drop_crate.iff", loc);
utils.setScriptVar(crate, "supply_drop.crateOwner", owner);
attachScript(crate, "systems.combat.combat_supply_drop_crate");
String itemString = "";
switch (supplyId)
{
case 0:
static_item.createNewItemFunction("item_stimpack_a_02_01", crate);
static_item.createNewItemFunction("item_stimpack_a_02_01", crate);
static_item.createNewItemFunction("weapon_npe_grenade_frag_02_01", crate);
String foodList = "";
if (level <= LEVEL_LOW_CAP)
{
foodList = FOOD_LOW;
}
else if (level <= LEVEL_MID_CAP)
{
foodList = FOOD_MID;
}
else
{
foodList = FOOD_HIGH;
}
String[] foodItems = dataTableGetStringColumn(FOOD_TABLE, foodList);
for (int i = 0; i < FOOD_ITEMS; i++)
{
int r = rand(0, (foodItems.length - 1));
static_item.createNewItemFunction(foodItems[r], crate);
}
break;
case 1:
itemString = "item_off_temp_stimpack_02_01";
break;
case 2:
itemString = "item_off_temp_stimpack_02_02";
break;
case 3:
itemString = "item_off_temp_stimpack_02_03";
break;
case 4:
itemString = "item_off_temp_stimpack_02_04";
break;
case 5:
itemString = "item_off_temp_stimpack_02_05";
break;
case 6:
itemString = "item_off_temp_stimpack_02_06";
break;
case 7:
itemString = "item_off_temp_tactical_buff_02_01";
break;
case 8:
itemString = "item_off_temp_tactical_buff_02_02";
break;
case 9:
itemString = "item_off_temp_tactical_buff_02_03";
break;
case 10:
itemString = "item_off_temp_tactical_buff_02_04";
break;
case 11:
itemString = "item_off_temp_tactical_buff_02_05";
break;
case 12:
itemString = "item_off_temp_tactical_buff_02_06";
break;
}
if (supplyId > 0 && supplyId <= 12 && (itemString != null || !itemString.equals("")))
{
for (int i = 0; i < GROUP_SIZE; i++)
{
static_item.createNewItemFunction(itemString, crate);
}
}
dictionary d = new dictionary();
d.put("owner", owner);
messageTo(self, "startTakeOffSequence", d, 2.0f, false);
return SCRIPT_CONTINUE;
}
public int startTakeOffSequence(obj_id self, dictionary params) throws InterruptedException
{
queueCommand(self, (-1465754503), self, "", COMMAND_PRIORITY_FRONT);
setPosture(self, POSTURE_UPRIGHT);
messageTo(self, "cleanUp", null, 20.0f, false);
return SCRIPT_CONTINUE;
}
public int cleanUp(obj_id self, dictionary params) throws InterruptedException
{
destroyObject(self);
return SCRIPT_CONTINUE;
}
public void summonOfficerPet(obj_id owner, String itemString, location spawnPoint) throws InterruptedException
{
if (!pet_lib.hasMaxPets(owner, pet_lib.PET_TYPE_NPC) && !pet_lib.hasMaxStoredPetsOfType(owner, pet_lib.PET_TYPE_NPC))
{
obj_id hireling = create.createCreature(itemString, spawnPoint, true);
if (!isIdValid(hireling))
{
return;
}
setObjVar(hireling, "pet.petRestriction", 1);
obj_id petControlDevice = pet_lib.makeControlDevice(owner, hireling);
callable.setCallableCD(hireling, petControlDevice);
pet_lib.makePet(hireling, owner);
pet_lib.setupOfficerPetCommands(hireling);
ai_lib.setDefaultCalmBehavior(hireling, ai_lib.BEHAVIOR_STOP);
callable.setCallableLinks(owner, petControlDevice, hireling);
dictionary params = new dictionary();
params.put("pet", hireling);
params.put("master", owner);
params.put("controlDevice", petControlDevice);
messageTo(hireling, "handleAddMaster", params, 0, false);
}
return;
}
}
|
[
"tmoflash@gmail.com"
] |
tmoflash@gmail.com
|
b8a19d34cd9e3bbb0d9c3e38f174125c57755b6d
|
4c1e68e97de6ffaba06e484ee7bb6250ece1e62b
|
/embl-api-ff/src/main/java/uk/ac/ebi/embl/flatfile/reader/genbank/GenbankPersonMatcher.java
|
9b275bf3c7f99f689ec23c14c370c3b2b2e41dac
|
[
"Apache-2.0"
] |
permissive
|
ebi-wp/sequencetools
|
3f6d4e1b71f9c04381fc4d38b86e50d80edcc91d
|
f153055c6214351ee341279d43bfd36c1fc3abf1
|
refs/heads/master
| 2021-04-03T06:17:52.888129
| 2018-09-24T10:23:28
| 2018-09-26T10:45:32
| 124,373,736
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,923
|
java
|
/*******************************************************************************
* Copyright 2012 EMBL-EBI, Hinxton outstation
*
* 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 uk.ac.ebi.embl.flatfile.reader.genbank;
import java.util.regex.Pattern;
import uk.ac.ebi.embl.api.entry.reference.Person;
import uk.ac.ebi.embl.api.entry.reference.ReferenceFactory;
import uk.ac.ebi.embl.flatfile.FlatFileUtils;
import uk.ac.ebi.embl.flatfile.reader.FlatFileLineReader;
import uk.ac.ebi.embl.flatfile.reader.FlatFileMatcher;
public class GenbankPersonMatcher extends FlatFileMatcher {
public GenbankPersonMatcher(FlatFileLineReader reader) {
super(reader, PATTERN);
}
private static final Pattern PATTERN = Pattern.compile(
"^([^\\.]+)" + // surname
"(?:(?:\\,|\\s+)(\\s*[^\\s\\.]*\\s*\\..*))?$"); // first name
private static final int GROUP_SURNAME = 1;
private static final int GROUP_FIRST_NAME = 2;
public Person getPerson() {
String surname = getString(GROUP_SURNAME);
if (surname != null) {
surname = surname.trim();
}
String firstName = getString(GROUP_FIRST_NAME);
if (firstName != null) {
firstName = FlatFileUtils.shrink(firstName.trim(), '.');
}
return (new ReferenceFactory()).createPerson(
surname, firstName);
}
}
|
[
"reddyk@REDDYK-W10D.windows.ebi.ac.uk"
] |
reddyk@REDDYK-W10D.windows.ebi.ac.uk
|
23d533f8c7f49b7fb70e14147d6d075cb5ec8a37
|
4152d9c2720197f14de65c8270d8198e5163498a
|
/fluent-mybatis-test/src/test/java/cn/org/atool/fluent/mybatis/test/basedao/DeleteByQueryTest.java
|
493fc1f5e2384ecf2a1404ac3842a0b22cb6a1be
|
[
"Apache-2.0"
] |
permissive
|
ResultLv/fluent-mybatis
|
d0a56f98ad8c3b3bbcf95bffc7e630f763d58347
|
6642d98761757668e77b3ccc5defa670ae92b38e
|
refs/heads/master
| 2023-01-28T03:54:23.213526
| 2020-12-14T12:59:56
| 2020-12-14T12:59:56
| null | 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,012
|
java
|
package cn.org.atool.fluent.mybatis.test.basedao;
import cn.org.atool.fluent.mybatis.customize.StudentExtDao;
import cn.org.atool.fluent.mybatis.generate.ATM;
import cn.org.atool.fluent.mybatis.test.BaseTest;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.test4j.hamcrest.matcher.string.StringMode;
public class DeleteByQueryTest extends BaseTest {
@Autowired
private StudentExtDao dao;
@Test
public void test_deleteByQuery() throws Exception {
ATM.dataMap.student.initTable(10)
.userName.values(DataGenerator.increase("username_%d"))
.env.values("test_env")
.cleanAndInsert();
dao.deleteByQuery("username_4", "username_5", "username_7");
db.table(ATM.table.student).count().eq(7);
db.sqlList().wantFirstSql()
.eq("DELETE FROM student " +
"WHERE is_deleted = ? AND env = ? AND user_name IN (?, ?, ?)", StringMode.SameAsSpace);
}
}
|
[
"darui.wu@163.com"
] |
darui.wu@163.com
|
2b51f920e78a69054a829a3f4c356764f6cd7c71
|
be5474cbf69c76bddd2e485a2262b27858a2da1d
|
/main/java/com/grail/synchro/beans/ResearchPONum.java
|
aaad2cf5c15ad9c1e88ade554a7ee22d8da0ab15
|
[] |
no_license
|
Tejinder/Jive-8-src-code
|
1b3beaa48fb52d52aad75bac10d6ac0ca3e65c6c
|
72098a78e55583e147bac65a92888b5a6e611cf1
|
refs/heads/master
| 2020-04-01T17:04:00.699797
| 2019-03-18T11:09:21
| 2019-03-18T11:09:21
| 153,411,331
| 0
| 0
| null | null | null | null |
UTF-8
|
Java
| false
| false
| 1,189
|
java
|
package com.grail.synchro.beans;
import com.jive.api.entitlement.impl.ApiEntitlementImpl;
/**
* @author Tejinder
* @version 1.0
*/
public class ResearchPONum extends BeanObject {
private String budgetApproverId;
private String poNum;
private boolean poCheckBox;
public String getBudgetApproverId() {
return budgetApproverId;
}
public void setBudgetApproverId(String budgetApproverId) {
this.budgetApproverId = budgetApproverId;
}
public String getPoNum() {
return poNum;
}
public void setPoNum(String poNum) {
this.poNum = poNum;
}
public boolean isPoCheckBox() {
return poCheckBox;
}
public void setPoCheckBox(boolean poCheckBox) {
this.poCheckBox = poCheckBox;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (!(o instanceof ResearchPONum)) {
return false;
}
ResearchPONum that = (ResearchPONum) o;
if (budgetApproverId != that.budgetApproverId) {
return false;
}
return true;
}
@Override
public int hashCode() {
return Integer.valueOf(budgetApproverId);
}
}
|
[
"tejinder456@gmail.com"
] |
tejinder456@gmail.com
|
1797a628855fd6ef65e85ed95430573806e70de4
|
d24de9be4c3993d9dc726e9a3c74d9662c470226
|
/reverse/Rocketbank_All_3.12.4_source_from_JADX/sources/kotlin/io/CloseableKt.java
|
ad1f44b948952635324f5bc5832db7c53ad3b400
|
[] |
no_license
|
MEJIOMAH17/rocketbank-api
|
b18808ee4a2fdddd8b3045cd16655b0d82e0b13b
|
fc4eb0cbb4a8f52277fdb09a3b26b4cceef6ff79
|
refs/heads/master
| 2022-07-17T20:24:29.721131
| 2019-07-26T18:55:21
| 2019-07-26T18:55:21
| 198,698,231
| 4
| 0
| null | 2022-06-20T22:43:15
| 2019-07-24T19:31:49
|
Smali
|
UTF-8
|
Java
| false
| false
| 1,725
|
java
|
package kotlin.io;
import java.io.Closeable;
import kotlin.internal.PlatformImplementationsKt;
import kotlin.jvm.internal.Intrinsics;
/* compiled from: Closeable.kt */
public final class CloseableKt {
/* JADX WARNING: inconsistent code. */
/* Code decompiled incorrectly, please refer to instructions dump. */
private static final <T extends java.io.Closeable, R> R use(T r1, kotlin.jvm.functions.Function1<? super T, ? extends R> r2) {
/*
r0 = 0;
r2 = r2.invoke(r1); Catch:{ Throwable -> 0x000e }
kotlin.internal.PlatformImplementationsKt.apiVersionIsAtLeast$4868d312();
closeFinally(r1, r0);
return r2;
L_0x000c:
r2 = move-exception;
goto L_0x0010;
L_0x000e:
r0 = move-exception;
throw r0; Catch:{ all -> 0x000c }
L_0x0010:
kotlin.internal.PlatformImplementationsKt.apiVersionIsAtLeast$4868d312();
closeFinally(r1, r0);
throw r2;
*/
throw new UnsupportedOperationException("Method not decompiled: kotlin.io.CloseableKt.use(java.io.Closeable, kotlin.jvm.functions.Function1):R");
}
public static final void closeFinally(Closeable closeable, Throwable th) {
if (closeable != null) {
if (th == null) {
closeable.close();
return;
}
try {
closeable.close();
} catch (Closeable closeable2) {
Intrinsics.checkParameterIsNotNull(th, "$receiver");
Intrinsics.checkParameterIsNotNull(closeable2, "exception");
PlatformImplementationsKt.IMPLEMENTATIONS$287f0623.addSuppressed(th, closeable2);
}
}
}
}
|
[
"mekosichkin.ru"
] |
mekosichkin.ru
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.