blob_id stringlengths 40 40 | language stringclasses 1
value | repo_name stringlengths 5 132 | path stringlengths 2 382 | src_encoding stringclasses 34
values | length_bytes int64 9 3.8M | score float64 1.5 4.94 | int_score int64 2 5 | detected_licenses listlengths 0 142 | license_type stringclasses 2
values | text stringlengths 9 3.8M | download_success bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|---|
555be6e2de88f529a11d32da17b36e8f764c1edd | Java | liuniandxx/weego_share | /src/main/java/com/weego/main/dao/AttractionDao.java | UTF-8 | 1,404 | 2.265625 | 2 | [] | no_license | package com.weego.main.dao;
import java.util.ArrayList;
import java.util.List;
import org.bson.types.ObjectId;
import org.mongojack.JacksonDBCollection;
import org.springframework.stereotype.Repository;
import com.mongodb.BasicDBObject;
import com.mongodb.DB;
import com.mongodb.DBCollection;
import com.w... | true |
e348a63b502922d8ba3d509aa62499a8dac839ae | Java | flroexus/aelp | /AL-Game/src/com/aionemu/gameserver/model/autogroup/AutoPvPFFAInstance.java | UTF-8 | 1,733 | 1.960938 | 2 | [] | no_license | package com.aionemu.gameserver.model.autogroup;
import com.aionemu.gameserver.model.gameobjects.player.Player;
import com.aionemu.gameserver.model.instance.instancereward.PvPArenaReward;
import com.aionemu.gameserver.network.aion.serverpackets.SM_AUTO_GROUP;
import com.aionemu.gameserver.services.AutoGroupService;
imp... | true |
d72e9a5dcfbfffc7b77a79c6304b73636c2d1e80 | Java | prestodb/presto | /presto-product-tests/src/main/java/com/facebook/presto/tests/TlsTests.java | UTF-8 | 3,957 | 2.140625 | 2 | [
"Apache-2.0"
] | permissive | /*
* 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
* distribut... | true |
75f16a79c38488bca28fe5c03f0989edb965424f | Java | ShomariG/CardDemo | /src/csc241/Main.java | UTF-8 | 734 | 3.890625 | 4 | [] | no_license | package csc241;
import javax.swing.*;
public class Main {
public static void main(String[] args) {
// Create some cards
PlayingCard pc1 = new PlayingCard(Value.FIVE, Suit.SPADES); // Use the enumerator values as parameters
PlayingCard pc2 = new PlayingCard(Value.EIGHT, Suit.DIAMONDS);
... | true |
e2fdb229609c6d020e9cabf7754f0748fe38340f | Java | cheatcodezky/Wifi_humidifier_controuler | /app/src/main/java/com/tree/max/humidifier/WifiBroadcastReceiver.java | UTF-8 | 1,729 | 2.375 | 2 | [] | no_license | package com.tree.max.humidifier;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.net.wifi.p2p.WifiP2pManager;
import android.util.Log;
import android.widget.Toast;
/**
* Created by max on 17-5-20.
*/
public class WifiBroadcastReceiver extends ... | true |
16f4308f6f6f534bf8fbe4efff990ab2d0ab0fa0 | Java | VRSpring/WX-VRSpring-Server | /src/main/java/com/xie/bean/Point.java | UTF-8 | 1,451 | 2.34375 | 2 | [] | no_license | package com.xie.bean;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.xie.utils.DoubleSerializer;
import java.util.Date;
/**
* Created with IntelliJ IDEA.
*
* @Author xie
* @summary summary
* @Copyright (c) 2017, Lianjia Group All Rights Reserved.
* @Description To change this templa... | true |
fcb3282708cb0fc3923cd3a5cad55abd13730799 | Java | dbmdz/iiif-apis | /src/main/java/de/digitalcollections/iiif/model/GenericService.java | UTF-8 | 1,053 | 2.3125 | 2 | [
"MIT"
] | permissive | package de.digitalcollections.iiif.model;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.net.URI;
/**
* A generic service with an identifier and a profile.
*
* <p>Only for unknown services, please check if one of these matches your use case in... | true |
7c0f4c1c04e4bf1eb311e0ab30ddd9f4e9bc289f | Java | 17317815459/Android | /app/src/main/java/com/example/lalala/http/GetUserShareTask.java | UTF-8 | 602 | 1.960938 | 2 | [] | no_license | package com.example.lalala.http;
import android.os.AsyncTask;
import com.example.lalala.shared_info.SaveUser;
import com.google.gson.Gson;
public class GetUserShareTask extends AsyncTask<Void, Void, String> {
@Override
protected String doInBackground(Void... voids) {
return HttpHandler.doGet(HttpHand... | true |
725c293569085dfb7bc9510f8753bfc61a501377 | Java | ReddyVanya/LeetCode | /matrix-diagonal-sum/matrix-diagonal-sum.java | UTF-8 | 337 | 2.75 | 3 | [] | no_license | class Solution {
public int diagonalSum(int[][] mat) {
if(mat.length==1) return mat[0][0];
int sum=0;
for(int i=0; i<mat.length; i++)
{
sum = sum+mat[i][i]+mat[i][mat.length-i-1];
}
if(mat.length%2 ==1) sum = sum-mat[mat.length/2][mat.length/2];
re... | true |
319dfe634d78f8b665e7b297c4345fc39f3a3be9 | Java | cha63506/CompSecurity | /emoji-source/src/com/squareup/okhttp/internal/spdy/NameValueBlockReader$1.java | UTF-8 | 1,191 | 1.617188 | 2 | [] | no_license | // Decompiled by Jad v1.5.8e. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/kpdus/jad.html
// Decompiler options: braces fieldsfirst space lnc
package com.squareup.okhttp.internal.spdy;
import com.squareup.okhttp.internal.Util;
import java.io.IOException;
import java.io.InputStream;
//... | true |
b347d4fbbc24ec46c6470fb744f04d9a0ec71cdb | Java | amitsriv99/discovery-service | /src/main/java/com/labizy/services/content/beans/LabTestWithPricingPromoBean.java | UTF-8 | 416 | 1.796875 | 2 | [] | no_license | package com.labizy.services.content.beans;
import com.fasterxml.jackson.annotation.JsonInclude;
@JsonInclude(JsonInclude.Include.NON_NULL)
public class LabTestWithPricingPromoBean extends LabTestWithPricingBean{
private PromotionBean promotion;
public PromotionBean getPromotion() {
return promotion;
}... | true |
9a323e40540e40e7350db3e85a628b07e5eba386 | Java | theresakahale/Java-Projects | /ATM/src/assignment5/Account.java | UTF-8 | 777 | 3.046875 | 3 | [] | no_license | package assignment5;
public class Account {
private String account_number;
private String type;
private float balance;
public Account(String acc_numb, String t, float b) {
account_number = acc_numb;
type = t;
balance = b;
}
public String getAccount_number() {
return account_number;
}
... | true |
1ce607886fafac6ac74906df98d52b94b68d1aeb | Java | JordanAclarke/OrderMicroservice | /payment-service/src/main/java/com/jordanproject/ps/service/PaymentService.java | UTF-8 | 865 | 1.929688 | 2 | [] | no_license | package com.jordanproject.ps.service;
import java.util.List;
import java.util.Random;
import java.util.UUID;
import org.apache.tomcat.util.buf.UDecoder;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.jordanproject.ps.dao.PaymentDAO;
import com... | true |
6108e796f105a837920f4c5facff4e0c42138b7e | Java | MahmoodRaafat/Codeforces | /Problem Set 0002/B - The Least Round Way.java | UTF-8 | 3,786 | 3.390625 | 3 | [] | no_license | /*
B - The Least Round Way
There is a square matrix nxn, consisting of non-negative integer numbers. You
should find such a way on it that starts in the upper left cell of the matrix,
each following cell is to the right or down from the current cell, and the way
ends in the bottom right cell. Moreover, if we... | true |
369172dc2388825d609d43c37a625c50f472e584 | Java | Triple3h/Project1 | /src/cn/servlet/Goods/UpdateGoodsServlet.java | UTF-8 | 1,451 | 2.34375 | 2 | [] | no_license | package cn.servlet.Goods;
import cn.dao.GoodsDao;
import cn.entity.Goods;
import cn.utils.Goodsutils;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.io.Pr... | true |
47cb9fd4b7bede932e28b0de921ab5a887182a4f | Java | radtek/wintec_erp | /src/main/java/erp/chain/domain/DietPromotion.java | UTF-8 | 7,713 | 1.875 | 2 | [] | no_license | package erp.chain.domain;
import java.math.BigInteger;
import java.sql.Time;
import java.util.Date;
import java.util.Map;
/**
* Created by xumx on 2016/11/3.
*/
public class DietPromotion extends BaseDomain {
/**
* 促销编码
*/
String promotionCode;
/**
* 促销名称
*/
String promotionName... | true |
2555665501f6fd1bda8bc7f573f0f78b6b8f9d2b | Java | xbony2/Simple-RF-Wire | /src/main/java/xbony2/simplerfwire/BlockRFWire.java | UTF-8 | 736 | 2.34375 | 2 | [
"MIT"
] | permissive | package xbony2.simplerfwire;
import net.minecraft.block.Block;
import net.minecraft.block.material.Material;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.world.World;
public class BlockRFWire extends Block{
public BlockRFWire() {
super(Material.ir... | true |
34ce4c1a11a7fab1cbc14270c2ec99fa863bbb6a | Java | lywow/AliceEnglish | /app/src/main/java/com/alice/aliceenglish/util/Network.java | UTF-8 | 2,135 | 2.15625 | 2 | [] | no_license | package com.alice.aliceenglish.util;
import android.util.Log;
import com.alice.collector.data.Motion;
import com.alice.collector.data.MotionDAO;
import com.alice.collector.util.GsonUtil;
import com.alice.collector.util.SPUtil;
import com.google.gson.JsonObject;
import java.io.IOException;
import java.util.List;
impo... | true |
7f04805c1e80034409f7c8a284934bf7f7f47109 | Java | kisorbiswal/accounter | /src/com/vimukti/accounter/web/client/uibinder/setup/SetupSellTypeAndSalesTaxPage.java | UTF-8 | 8,335 | 1.640625 | 2 | [
"Apache-2.0"
] | permissive | /**
*
*/
package com.vimukti.accounter.web.client.uibinder.setup;
import com.google.gwt.core.client.GWT;
import com.google.gwt.event.dom.client.ClickEvent;
import com.google.gwt.event.dom.client.ClickHandler;
import com.google.gwt.uibinder.client.UiBinder;
import com.google.gwt.uibinder.client.UiField;
im... | true |
e196311c9d5e9bbda93cf5f90187b706cabb07e4 | Java | Kmet90/JavaProgrammingFundamentals2 | /src/FinalExamsJavaFundamentals/NeedForSpeedIII_03.java | UTF-8 | 3,581 | 3.765625 | 4 | [] | no_license | package FinalExamsJavaFundamentals;
import java.util.*;
public class NeedForSpeedIII_03 {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int n = Integer.parseInt(scanner.nextLine());
Map<String, Integer> carsMileage = new TreeMap<>();
Map<String... | true |
f980e08e8b9814bfa6c0c007c3db68c16640446a | Java | nutzam/nutzmore | /nutz-plugins-views/src/main/java/org/nutz/plugins/view/ViewMakerProxy.java | UTF-8 | 825 | 2.5625 | 3 | [
"Apache-2.0"
] | permissive | package org.nutz.plugins.view;
import java.util.ArrayList;
import java.util.List;
import org.nutz.ioc.Ioc;
import org.nutz.mvc.View;
import org.nutz.mvc.ViewMaker;
/**
* 从Ioc中加载ViewMaker,得到View就返回
* @author wendal
*/
public class ViewMakerProxy implements ViewMaker {
private List<ViewMaker> list... | true |
ae5c52a9abb106faea07d16bfbf3d87bbbfbdabc | Java | primesign/pdf-as-4 | /pdf-as-lib/src/test/java/at/gv/egiz/pdfas/lib/test/mains/LegacySLExtractor.java | UTF-8 | 2,688 | 2.21875 | 2 | [] | no_license | package at.gv.egiz.pdfas.lib.test.mains;
import static org.junit.Assert.*;
import org.junit.Test;
import at.gv.egiz.pdfas.common.exceptions.SLPdfAsException;
import at.gv.egiz.sl.util.BKUSLConnector;
public class LegacySLExtractor {
public static final String TEST_LEGACY_RESPONSE = "<?xml version=\"1.0\" encoding... | true |
3a3d5d917746fb97947aa1e92fb0670e8a2bf105 | Java | niclasko/FuseBase | /src/JSONAssociativeArray.java | UTF-8 | 2,160 | 2.734375 | 3 | [
"Apache-2.0"
] | permissive | /*
* Copyright (c) 2018 "Niclas Kjall-Ohlsson, Bjornar Fjoren"
*
* 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 b... | true |
7dd97b2d96bf297f100de6732bdc575033a02bc3 | Java | polhek/java-learning-mooc | /part04-Part04_31.SportStatistics/src/main/java/SportStatistics.java | UTF-8 | 1,743 | 3.5 | 4 | [] | no_license |
import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.Scanner;
public class SportStatistics {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
System.out.println("File:");
String fileName = scan.nextLine();
try (Scanner fileRead... | true |
6dd7f4244a8a81891c71284442d8947833831305 | Java | namu1714/pubgcommu | /src/main/java/com/project/pubgcommu/web/dto/team/TeamSaveRequestDto.java | UTF-8 | 580 | 2.0625 | 2 | [] | no_license | package com.project.pubgcommu.web.dto.team;
import com.project.pubgcommu.web.dto.player.PlayerSaveRequestDto;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import java.util.List;
@Getter
@NoArgsConstructor
public class TeamSaveRequestDto {
private String name;
private List<Pla... | true |
f814aa5aaad26cb2aad21fbe7fa3aa39a1596d27 | Java | Mithrandir21/primenetworks | /Prime/PrimeTesting/src/jUnitTests/ComponentsManagmentTest.java | UTF-8 | 5,877 | 3.453125 | 3 | [] | no_license | package jUnitTests;
import junit.framework.TestCase;
import managment.ArrayManagment;
import managment.ComponentsManagment;
import objects.Object;
import objects.clientObjects.Desktop;
import objects.peripheralObjects.ExternalHDD;
import objects.serverObjects.HTTPServer;
import org.junit.Test;
import exceptions.Obj... | true |
a5f4888398636345450abdbdafe2da3b3c0236a7 | Java | 35099644/WechatBot | /app/src/main/java/com/vicxiao/weixinhacker/message/TextMessage.java | UTF-8 | 489 | 2.40625 | 2 | [] | no_license | package com.vicxiao.weixinhacker.message;
/**
* Created by vic on 15-12-13.
*/
public class TextMessage extends Message{
public static final char AT_SEPARATOR = (char)8197;
public static final String AT_FORMATE = "@%s \n";
public TextMessage(long createTime, String talker, String id, String content) {
... | true |
5daf1da910fd58610029785ac42280408b114d88 | Java | dtin/MiniSocialNetwork | /src/java/tindd/post/StandardPostDetail.java | UTF-8 | 1,565 | 2.203125 | 2 | [] | no_license | /*
* 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 tindd.post;
import java.io.Serializable;
import tindd.tblPosts.TblPostsDTO;
/**
*
* @author Tin
*/
public class StandardPo... | true |
1ace857b5e49767c80f5ec45d9520c9f53fe1512 | Java | GDGBVCOE/javabootcamp | /Java1.0/Calculator.java | UTF-8 | 818 | 4.03125 | 4 | [] | no_license | import java.util.Scanner;
public class Calculator {
public static void main(String Args []){
int choice,num1,num2;
float answer;
Scanner scanner = new Scanner(System.in);
System.out.println("Enter Your Choice ");
System.out.println("Press 1 For Addition");
System.out.println("Press 2 For Subtion");
Sys... | true |
4cea8bb3571ed0d80fe1580d8570d86cf1703217 | Java | rojochen/jpoet-demo | /src/main/java/TypeGen.java | UTF-8 | 733 | 2.53125 | 3 | [] | no_license |
import java.io.File;
import java.io.IOException;
import java.io.PrintStream;
import javax.lang.model.element.Modifier;
import com.squareup.javapoet.JavaFile;
import com.squareup.javapoet.TypeSpec;
public class TypeGen {
public static void main(String[] args) throws IOException {
//PrintStream stream = new Prin... | true |
bb78ebd6c9efe25e3c4beed7d66a124cff74a249 | Java | vinayakbangar/Safar-SpringBoot | /src/main/java/com/lti/bean/BusTypeRate.java | UTF-8 | 913 | 2.09375 | 2 | [] | no_license | package com.lti.bean;
import javax.persistence.*;
import java.math.BigDecimal;
/**
* The persistent class for the BUS_TYPE_RATE database table.
*
*/
@Entity
@Table(name="BUS_TYPE_RATE")
public class BusTypeRate {
@Id
@Column(name="BUS_TYPE_ID")
private long busTypeId;
@Column(name="RATE_P... | true |
56dca1b98a0db45a735d766b9795877ae35ca626 | Java | KingsleyTeam/Wisdom-Island | /android/Wisdom-Island/src/com/drcom/drpalm/Activitys/consultation/FeedBackActivity.java | UTF-8 | 8,821 | 1.664063 | 2 | [] | no_license | package com.drcom.drpalm.Activitys.consultation;
import android.app.AlertDialog;
import android.app.Dialog;
import android.content.Context;
import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;... | true |
f953e22c18cc51f71afed63c78cab08fddd4725f | Java | guosen/GitGuosen | /Joke/src/com/joke/android/RefreshListviewActivity.java | UTF-8 | 4,408 | 2.40625 | 2 | [] | no_license | package com.joke.android;
import java.util.ArrayList;
import java.util.LinkedList;
import java.util.List;
import android.app.Activity;
import android.content.Intent;
import android.os.AsyncTask;
import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import com.joke.android.entity.JokeCo... | true |
8998efb6953a09ffb22a5ffc698f017f39402086 | Java | cqc-hub/1062170019 | /12-Manager/src/yp/cqc/dao/UserDao.java | GB18030 | 416 | 2.109375 | 2 | [] | no_license | package yp.cqc.dao;
import java.util.List;
import yp.cqc.pojo.User;
public interface UserDao {
/*
* ûѯûϢ
*
* return ѯûϢ
*/
User checkUserLoginDao(String uname,String pwd);
//
int userChangePwdDao(String newPwd, int uid);
//ȡûϢ
List<User> checkUserShowDao();
//ע
int checkUserRegnDao(User u);
}
| true |
77507f95bd988f2d621fccd380a77b2805ab4824 | Java | Dong-gi/Dong-gi.github.io | /Repositories/STS/web-app/src/main/java/io/github/donggi/controller/SleepController.java | UTF-8 | 674 | 2.5625 | 3 | [
"MIT"
] | permissive | package io.github.donggi.controller;
import org.springframework.scheduling.annotation.Async;
import org.springframework.web.bind.annotation.RestController;
@RestController
public class SleepController {
@Async
public void justSleep() {
// 결과를 대기할 필요가 있다면 Future를 반환하면 된다
// org.springframework... | true |
872b12967ec2d160698a6997e0c35515d2152376 | Java | miracle2k/hibiscus-cvsimport | /src/de/willuhn/jameica/hbci/calendar/DauerauftragAppointmentProvider.java | ISO-8859-1 | 8,144 | 2.203125 | 2 | [] | no_license | /**********************************************************************
* $Source$
* $Revision$
* $Date$
* $Author$
*
* Copyright (c) by willuhn - software & services
* All rights reserved
*
**********************************************************************/
package de.willuhn.jameica.hbci.calendar;
impo... | true |
a5aa24ac8d925515883dc0e8ccff670133ee7777 | Java | muthenberg/vertx-multipart-api-spec-example | /src/main/java/de/cyface/verticle/MainVerticle.java | UTF-8 | 1,618 | 2.25 | 2 | [] | no_license | package de.cyface.verticle;
import io.vertx.core.AbstractVerticle;
import io.vertx.core.Future;
import io.vertx.ext.web.Router;
import io.vertx.ext.web.api.contract.openapi3.OpenAPI3RouterFactory;
import io.vertx.ext.web.handler.BodyHandler;
/**
*
* @author Klemens Muthmann
* @version 1.0.0
* @since 1.0.0
*/
pu... | true |
46ad4a61540e526cc9a86cc058bd4c54a3f61460 | Java | fillzero/test-ha | /src/binpack/GenProtectVM.java | UTF-8 | 1,032 | 2.53125 | 3 | [] | no_license | package binpack;
public class GenProtectVM {
public static void main(String[] args) {
test();
}
public static void test() {
int host_num = 16;//32;//16;
int vm_num_per_host = 8;//4;//8;
int order = 0;
// order = 0 : H1_VM_01, H1_VM_02, ..., H1_VM_08; H2_VM_01, ...., H2_VM_08; ..., H16_VM_08
// order =... | true |
3a0ad571b73b9ef0eb5fbed91e1be988e2f82bc4 | Java | sakitani/Fiap2021---Digital-Business | /Estudo/src/br/com/fiap/imposto/strategy/Imposto.java | UTF-8 | 166 | 1.929688 | 2 | [] | no_license | package br.com.fiap.imposto.strategy;
import br.com.fiap.pedido.state.Pedido;
public interface Imposto {
//STRATEGY
public double calcular(Pedido pedido);
}
| true |
ea26280b7dfdfad820f7132f60382e6a2c3feb71 | Java | dnzyx/superclass | /app/src/main/java/com/fivestar/superclass/index_window.java | UTF-8 | 1,352 | 2.296875 | 2 | [] | no_license | package com.fivestar.superclass;
import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widg... | true |
45041a03089a3b0379c4018987caed2e8e8e243b | Java | Sourabhlpu/NewsFeedV1 | /app/src/main/java/com/example/personal/newsfeeder/data/NewsPreferences.java | UTF-8 | 1,991 | 2.140625 | 2 | [] | no_license | package com.example.personal.newsfeeder.data;
import android.content.Context;
import android.content.SharedPreferences;
import android.preference.PreferenceManager;
import com.example.personal.newsfeeder.R;
/**
* Created by personal on 8/29/2017.
*/
public class NewsPreferences {
private static int BookmarkC... | true |
25f29665b2d2e43087ef29615da1d9facae58cb0 | Java | loai-kanou/java2php | /php/src/java/io/BufferedReader.java | UTF-8 | 229 | 2.171875 | 2 | [] | no_license | package PLACEHOLDERS;
public class BufferedReader {
public java.lang.String readLine() /*throws IOException*/ {
return " ";
}
public void close() throws java.io.IOException {
}
public int read() {
return 0;
}
} | true |
7965facdeec08e178a05645b4bd1ba8434fc6577 | Java | WenhaoGe/Leetcode | /easy/Single Number/solution.java | UTF-8 | 562 | 3.078125 | 3 | [] | no_license | class Solution {
public int singleNumber(int[] nums) {
/*HashSet<Integer> set = new HashSet<Integer>();
for (int n : nums) {
if (!set.add(n))
set.remove(n);
}
Iterator<Integer> it = set.iterator();
return it.next();*/
int result=-1;
Set<Integer> set = new HashSet();
for(int num:... | true |
d753a74f07632727844d757c62815494c7f490ab | Java | Nkosi-Mkh/Java | /Conditionals/ConditionalsWthCompOp.java | UTF-8 | 364 | 3.28125 | 3 | [] | no_license | public class ConditionalsWthCompOp
{
//main method
public static void main (String[] args)
{
int x= 7;
int y=9;
int z=12;
boolean compare;
//Compare: ==, >=,<=, <, >, !=
//Assign: =
compare= x<y;
System.out.println("Hello");
Sy... | true |
35b9f4132b4dde4144576fff95e32ac4c92122d4 | Java | Oleksandr-CH/Amwell | /src/test/java/automationPractice/utilities/commonMethods.java | UTF-8 | 416 | 1.890625 | 2 | [] | no_license | package automationPractice.utilities;
import java.util.Map;
public interface commonMethods {
public default void clickButton(String button){}
public default void enterValue (String field, String value){}
public default void validate (String field, String expected){}
public default void select (Str... | true |
ea24c988113355a997578cdb50e3cece564685d2 | Java | sangyuruo/MyAndroidCode | /SDLDemo/SdlAutoTester/src/com/livio/sdl/dialogs/AutoTestJsonFlipperDialog.java | UTF-8 | 3,224 | 2.703125 | 3 | [] | no_license | package com.livio.sdl.dialogs;
import java.util.List;
import net.suntec.sdl.R;
import net.suntec.sdl.autotester.dto.TestSample;
import android.content.Context;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.ImageButton;
import android.widget.TextView;
import com.livio.sdl.u... | true |
24d90cc789055c161e6a6eca5b93777caf50f569 | Java | jbarrancoandrade/comercializadora | /src/java/POJOS/TesCtasBancariasxUsu.java | UTF-8 | 545 | 1.789063 | 2 | [] | no_license | package POJOS;
// Generated 5/12/2014 10:43:46 AM by Hibernate Tools 4.3.1
/**
* TesCtasBancariasxUsu generated by hbm2java
*/
public class TesCtasBancariasxUsu implements java.io.Serializable {
private TesCtasBancariasxUsuId id;
public TesCtasBancariasxUsu() {
}
public TesCtasBancariasxUsu(T... | true |
a43271960d7aa07ab493233adc5aadb1f05f2292 | Java | lenik/stack | /plover/modeling/plover-disp/src/main/java/com/bee32/plover/disp/IDispatcher.java | UTF-8 | 529 | 2.234375 | 2 | [] | no_license | package com.bee32.plover.disp;
import com.bee32.plover.arch.IComponent;
/**
* URI-style path dispatcher.
* <p>
* Plover-dispatcher supersedes the Stapler dispatcher.
*
* @see org.kohsuke.stapler.Dispatcher
*/
public interface IDispatcher
extends IDispatchable, IComponent {
/**
* The order of t... | true |
1999ebb9824be13452beb3dfff682094e453f3ff | Java | JamesZhaoLu/JavaHomeworkCode | /week4homework/NumberGenerator.java | UTF-8 | 1,512 | 3.28125 | 3 | [] | no_license | /*
* 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 week4homework;
import java.io.FileWriter;
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileNotFoundExcept... | true |
94c18e1db82bb643f4df06d130898a30e4b610ce | Java | royxpf/cloud | /src/main/java/com/baizhitong/resource/dao/rel/sqlserver/RelQuestionGradeDaoImpl.java | UTF-8 | 2,097 | 2.03125 | 2 | [] | no_license | package com.baizhitong.resource.dao.rel.sqlserver;
import org.springframework.stereotype.Service;
import com.baizhitong.resource.common.core.dao.BaseSqlServerDao;
import com.baizhitong.resource.dao.rel.RelQuestionGradeDao;
import com.baizhitong.resource.model.rel.RelQuestionGrade;
/**
* 试题与年级关系实现
*
* @author lus... | true |
bbe8a8114f3d6cc4dd6eebc4a0f238e5dd28ac78 | Java | yaozd/com.yzd.jutils | /com.yzd.jutils/src/main/java/com/yzd/jutils/springBoot/schedule3/base/AbstractJob.java | UTF-8 | 1,132 | 2.640625 | 3 | [] | no_license | package com.yzd.jutils.springBoot.schedule3.base;
import org.apache.commons.lang3.StringUtils;
import java.util.concurrent.TimeUnit;
/**
* Created by zd.yao on 2017/7/7.
*/
public class AbstractJob {
/**
* 从redis 里面读取消息可放到一个单独的抽象类里AbstractJob中,可以使代码更加清楚
* @param listKey 消息队列的key
*... | true |
2c45059f4111ca2b2d89c3bd326714bf45d4478d | Java | blessonmathewsam/CodeingPractice | /src/Strings/StringDiff.java | UTF-8 | 1,279 | 3.46875 | 3 | [] | no_license | package Strings;
import java.util.HashMap;
/**
*
*/
/**
* @author blessonm
*
*/
public class StringDiff {
/**
* @param args
*/
public static void main(String[] args) {
String s = "ymbgaraibkfmvocpizdydugvalagaivdbfsfbepeyccqfepzvtpyxtbadkhmwmoswrcxnargtlswqemafandgkmydtimuzvjwxvlfwlhvk... | true |
b299116838a31364ef42b689271bd9eb8a24df8d | Java | xxd137494375/jianzhioffer | /src/jianzhioffer/shu/ex4.java | UTF-8 | 2,517 | 3.875 | 4 | [] | no_license | package jianzhioffer.shu;
import java.util.*;
public class ex4 {
/*
重建二叉树
输入某二叉树的前序遍历和中序遍历的结果,请重建出该二叉树。
假设输入的前序遍历和中序遍历的结果中都不含重复的数字。例
如输入前序遍历序列{1,2,4,7,3,5,6,8}和中序遍历序列{4,7,2,1,5,3,8,6},则重建二叉树并返回。
*/
/**
* 自己最简单的想法
* @param pre
* @param in
... | true |
7117c4bd9ca0d7813ae66928d1cecd851449dd0a | Java | bc0086/JavaWebSTS | /src/main/java/com/spring/bcjin/Email/MailController.java | UTF-8 | 1,284 | 2.453125 | 2 | [] | no_license | //package com.spring.bcjin.Email;
//
//import java.io.PrintWriter;
//
//import javax.servlet.http.HttpServletRequest;
//import javax.servlet.http.HttpServletResponse;
//
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.scheduling.annotation.EnableAsync;
//import org... | true |
6b129974abba7cb40f8f731847ae867859786533 | Java | HenwiiZ/leetcode-solution | /122. Best Time to Buy and Sell Stock II.java | UTF-8 | 1,511 | 3.421875 | 3 | [] | no_license | class Solution {
public int maxProfit(int[] prices) {
int i = 0;
int valley = prices[0];
int peak = prices[0];
int maxprofit = 0;
while (i < prices.length - 1) {
while (i < prices.length - 1 && prices[i] >= prices[i + 1])
i++;
valley = ... | true |
c9f20fa7a9d431f7b5e3457300c55e31f8e5ef9e | Java | ktottempudi/libraryManagement | /src/main/java/com/example/libraryManagement/service/BookServiceImpl.java | UTF-8 | 1,243 | 2.109375 | 2 | [] | no_license | package com.example.libraryManagement.service;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.example.libraryManagement.entity.Book;
import com.example.libraryManagement.repository.BookRepository;
@Service
public class ... | true |
ca1e29ec5f30a6f2a099c246b6a0c0f0c90f3816 | Java | Vylegzv/design-patterns-java | /creational/Singleton/src/com/vylegzv/singleton/SingletonExample.java | UTF-8 | 6,145 | 3.71875 | 4 | [
"MIT"
] | permissive | package com.vylegzv.singleton;
/**
* The Singleton is a creational design pattern that ensures that only one
* instance of a class is created and provides a global point of access to the
* object.
* <p>
* Advantages:
* <ul>
* <li>Better memory usage, because the object is not created on each request.
* </ul>
... | true |
4808249f70fc5d6fabc5fa18373a16cc4d1af83c | Java | douglasgousheng/flink-demo | /src/main/java/state/Flink01_State_Operator_3.java | UTF-8 | 2,567 | 2.875 | 3 | [] | no_license | package state;
import org.apache.flink.api.common.state.BroadcastState;
import org.apache.flink.api.common.state.MapStateDescriptor;
import org.apache.flink.api.common.state.ReadOnlyBroadcastState;
import org.apache.flink.streaming.api.datastream.BroadcastStream;
import org.apache.flink.streaming.api.datastream.DataSt... | true |
1fce645cf147aeb5bddb3ad0c8c6d5696f182440 | Java | chamilaw1/sif3-framework-java | /SIF3InfraREST/sif3Common/src/sif3/common/header/HeaderValues.java | UTF-8 | 1,824 | 2.0625 | 2 | [
"Apache-2.0"
] | permissive | /*
* HeaderValues.java
* Created: 19/11/2013
*
* Copyright 2013 Systemic Pty Ltd
*
* 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/LIC... | true |
d55ccf56d79b23f201eb2d2c6dc0d83d0f3be56e | Java | andrew-waite/Acercraft-Plugins | /acergun/src/com/acercraft/AcerGun/Throwable.java | UTF-8 | 1,136 | 1.898438 | 2 | [] | no_license | package com.acercraft.AcerGun;
import org.bukkit.Material;
public class Throwable extends Gun
{
public Throwable(main plugin, Material ammoMat)
{
super(plugin, ammoMat, ammoMat);
}
public Throwable(main main) {
super(main);
}
public Gun clone()
{
Throwable g = new Throwable(this.plugin, Ma... | true |
3e9997af330bd5167205e366d9c605aa6261e3d0 | Java | dima-online/voting_back | /core/src/main/java/kz/bsbnb/controller/impl/ChatControllerImpl.java | UTF-8 | 6,429 | 2.265625 | 2 | [] | no_license | package kz.bsbnb.controller.impl;
import kz.bsbnb.common.consts.MessageType;
import kz.bsbnb.common.model.Chat;
import kz.bsbnb.common.model.ChatMessage;
import kz.bsbnb.controller.IChatController;
import kz.bsbnb.processor.ChatProcessor;
import kz.bsbnb.util.SimpleResponse;
import org.springframework.beans.factory.an... | true |
35bd2e7266cba766e9b1bbbc04e7f9b2246e856b | Java | calee14/JavaChallenges | /src/primefactors/largestprimefactor.java | UTF-8 | 931 | 3.4375 | 3 | [] | no_license | package primefactors;
import java.util.*;
public class largestprimefactor {
public static List<Integer> findprimefactors(long primeNum) {
List<Integer> factors = new ArrayList<>();
int num = 2;
while(num * num < primeNum) {
while(primeNum % num == 0) {
primeNum /= num;
factors.add(num);
}
num +... | true |
6426afb11417dbb6181cb962cee3dcf357956600 | Java | Mendesdj/University-Projects | /Human-Computer Interaction/Android App/app/src/main/java/pt/unl/fct/di/www/canicookit/DietsActivity.java | UTF-8 | 3,423 | 2.28125 | 2 | [] | no_license | package pt.unl.fct.di.www.canicookit;
import android.content.Intent;
import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.view.View;
import android.widget.AdapterView;
import android.widget.FrameLayout;
import android.widget.ListView;
import java.util.ArrayList;
import j... | true |
41c7c90a0d7883b2d2641739e2b0ccb21998ec5a | Java | 422517423/QYDS | /qyds-dao/src/main/java/net/dlyt/qyds/dao/ext/ComDistrictMapperExt.java | UTF-8 | 335 | 1.609375 | 2 | [] | no_license | package net.dlyt.qyds.dao.ext;
import net.dlyt.qyds.common.dto.ComDistrict;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;
import java.util.List;
@Repository
public interface ComDistrictMapperExt {
List<ComDistrict> selectByParentId(@Param(value = "parentId") Strin... | true |
70a4a7a22b9c617ab01cbba5b83076eedeb98192 | Java | emmar137/NewDTApp | /DiscipleTools/src/test/java/BaseScreen/ScreenBase.java | UTF-8 | 1,584 | 2.203125 | 2 | [] | no_license | package BaseScreen;
import org.openqa.selenium.support.PageFactory;
import org.openqa.selenium.support.ui.ExpectedConditions;
import org.openqa.selenium.support.ui.WebDriverWait;
import io.appium.java_client.MobileElement;
import io.appium.java_client.TouchAction;
import io.appium.java_client.android.AndroidDriver;
i... | true |
1937d8161988a5b14cbff45c4fb36cb770e1fd7d | Java | personaluser01/smartDrugBox | /app/src/main/java/com/siehuai/smartdrugbox/User/view/OrderMedicine/OrderMedicineFragment.java | UTF-8 | 9,820 | 1.851563 | 2 | [] | no_license | package com.siehuai.smartdrugbox.User.view.OrderMedicine;
import android.content.DialogInterface;
import android.content.Intent;
import android.databinding.DataBindingUtil;
import android.graphics.Bitmap;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
imp... | true |
dc60f0f13561c7bd751be42549a7e419b0a90784 | Java | Gitchandan110/All-Project | /ArtifactIdAppium/src/test/java/com/appium/commonutils/Base.java | UTF-8 | 5,941 | 1.851563 | 2 | [] | no_license | package com.appium.commonutils;
import static org.testng.Assert.assertNotNull;
import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;
import java.util.concurrent.TimeUnit;... | true |
fca36e165cfc88ea87c9eee2070e1df58211c06f | Java | manikantaabhi/Codechef | /codecheff/src/codecheff/Mani.java | UTF-8 | 1,173 | 2.8125 | 3 | [] | no_license | package codecheff;
import java.math.BigInteger;
import java.util.Scanner;
import java.math.BigInteger;
public class Mani {
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner sc =new Scanner (System.in);
BigInteger N=sc.nextBigInteger();
BigInteger tot_rooms=N.multi... | true |
daf65b1073cf71c5e626eee33f5c62910457aa66 | Java | bhobin/SSUThreeMeals | /app/src/main/java/com/example/user/androidproject/fragment/Fragment1.java | UTF-8 | 3,468 | 2.25 | 2 | [] | no_license | package com.example.user.androidproject.fragment;
import android.content.Intent;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import com.example.user.androidproject.MenuAc... | true |
1af5e76c52d7c43eac52ad7cb6c3ab58c37e90d4 | Java | hanifmzein/Mobile.PPKApps | /app/src/main/java/com/uinsk/mobileppkapps/adapter/DosenAdapter.java | UTF-8 | 1,611 | 2.390625 | 2 | [] | no_license | package com.uinsk.mobileppkapps.adapter;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView;
import com.uinsk.mobileppkapps.R;
import com.uinsk.mobileppkapps.... | true |
cab7b1c70bc558d0927158dcd3af8f7364b65652 | Java | chao313/demo_elasticsearch | /src/main/java/demo/elastic/search/controller/origin/CCRController.java | UTF-8 | 1,606 | 1.929688 | 2 | [] | no_license | package demo.elastic.search.controller.origin;
import com.alibaba.fastjson.JSONObject;
import demo.elastic.search.config.Bootstrap;
import demo.elastic.search.config.web.CustomInterceptConfig;
import demo.elastic.search.feign.CCRService;
import demo.elastic.search.framework.Response;
import demo.elastic.search.thread.... | true |
07c147fd655ec88df91e2196deeea44c5c19d6cb | Java | helloznan/springCloudSamples | /test samples/micro-weather-basic/src/main/java/com/waylau/spring/cloud/weather/service/WeatherDataService.java | UTF-8 | 538 | 1.875 | 2 | [] | no_license | package com.waylau.spring.cloud.weather.service;
import com.alibaba.fastjson.JSONObject;
import com.waylau.spring.cloud.weather.vo.WeatherResponse;
/**
* 天气数据服务
* @author zhengnan
*
*/
public interface WeatherDataService {
/**
* 根据城市ID来查询数据
* @param cityId
* @return
*
* @author zhengnan
*/
JSONObjec... | true |
91b8e5dc0cd638d78b6d77c6d33d1acf32f8dbbf | Java | aaron1taskera/crypto-prediction-ai | /PoloniexWatcher/src/models/LinearRegressionModel.java | UTF-8 | 3,147 | 3.015625 | 3 | [
"Unlicense"
] | permissive | package models;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.time.Instant;
import java.util.ArrayList;
public class LinearRegressionModel {
public double[] maxCoefficients;
public double maxScoreCoefficient;
public double[] coefficients;
public double scoreCoefficien... | true |
4345ccb08b380777ac1b84d55273bb28bcb5fe73 | Java | daniand17/JavaPhysicsEngine | /game_engine/src/objects/TestRect.java | UTF-8 | 1,400 | 2.890625 | 3 | [] | no_license | package objects;
import game_engine.GameObject;
import game_engine.Vector2;
import graphics.GraphicsThread;
import graphics.Renderer;
import graphics.Renderer.Renderers;
import physics.Collider;
import physics.Collider.Colliders;
import physics.Rigidbody2D;
/**
* This class is simply a test rectangle wit... | true |
8068619bce89b803a2fdd287069065da614112f9 | Java | djrausch/BillTracker | /app/src/main/java/com/djrausch/billtracker/receivers/NotificationReceiver.java | UTF-8 | 1,392 | 2.15625 | 2 | [] | no_license | package com.djrausch.billtracker.receivers;
import android.app.NotificationManager;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import com.djrausch.billtracker.BillTrackerApplication;
import com.djrausch.billtracker.models.Bill;
import com.djrausch.billtrac... | true |
a5efb24558259e3c8e2592d3e2a58bb74e447a19 | Java | xyin96/HackUMBC | /MaraudersMap/src/com/example/maraudersmap/Data.java | UTF-8 | 2,004 | 2.203125 | 2 | [] | no_license | package com.example.maraudersmap;
import java.util.ArrayList;
import java.util.HashMap;
import org.json.JSONException;
import org.json.JSONObject;
import android.content.Context;
import android.graphics.Bitmap;
import android.graphics.Bitmap.Config;
import android.graphics.drawable.PictureDrawable;
import com.googl... | true |
94cb5faf0d8c04bf595f573e90c2fb3c950fa5e2 | Java | hsy-hub/springboot | /src/main/java/com/example/demo/tool/Tool.java | UTF-8 | 511 | 1.96875 | 2 | [] | no_license | package com.example.demo.tool;
import net.sf.json.JSONArray;
import java.util.HashMap;
import java.util.Map;
public class Tool {
public static Map<String,Object> testLayui(Object object,int page,int limit){
Map<String,Object> returnTable = new HashMap<>();
returnTable.put("code",0);
retu... | true |
ba0d3f3cbb15f19904e2c322c38f93bfd13d91f5 | Java | falchek/designpatterns | /DesignPatterns/src/compound/mvc/duck/DuckSimulator.java | UTF-8 | 1,682 | 3.234375 | 3 | [] | no_license | package compound.mvc.duck;
public class DuckSimulator {
public static void main(String[] args) {
DuckSimulator simulator = new DuckSimulator();
AbstractDuckFactory duckFactory = new CountingDuckFactory();
simulator.simulate(duckFactory);
}
void simulate(AbstractDuckFactory duckFactory) {
//Quackable ma... | true |
e84851ee08e6130204794765b1937da3bb738ec7 | Java | yash-93/MCA | /SEM3/Java Programs/StringOperations.java | UTF-8 | 4,170 | 3.921875 | 4 | [] | no_license | import java.util.Scanner;
import java.lang.String;
class StringOperations{
static String revStr(String str){
String rev = "";
for(int i = str.length() - 1; i >= 0; i--)
{
rev = rev + str.charAt(i);
}
return rev;
}
public static void main(String[] args) {
boolean flag = true;
char ch;
Sca... | true |
34bac0d767bdd8e99bc667e48e34ee6273308d8f | Java | WeilerWebServices/Sonatype | /emma4it-maven-plugin/src/main/java/org/sonatype/maven/plugin/emma4it/CopyRepositoryMojo.java | UTF-8 | 6,968 | 1.734375 | 2 | [] | no_license | package org.sonatype.maven.plugin.emma4it;
import java.io.File;
import java.io.IOException;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
import org.apache.commons.io.FileUtils;
import org.apache.maven.artifact.Artifact;
import org.apache.maven.artifact.factory.ArtifactFactory;
import org.apa... | true |
9168d814005d7a47154a06a10ce62857a67e2ec0 | Java | christherama/fueleconomy | /src/main/java/io/rama/fueleconomy/NhtsaVinDecodingService.java | UTF-8 | 1,707 | 2.5 | 2 | [] | no_license | package io.rama.fueleconomy;
import org.springframework.stereotype.Service;
import org.springframework.web.client.RestTemplate;
import java.util.HashMap;
import java.util.Map;
@Service
public class NhtsaVinDecodingService implements VinDecodingService {
private final RestTemplate restTemplate;
private final... | true |
252d40aa66ea322868d7c7cfef8748ce19ffb2b8 | Java | mishkapp/square-kit | /src/main/java/com/mishkapp/minecraft/plugins/squarekit/utils/DamageUtils.java | UTF-8 | 1,524 | 2.328125 | 2 | [] | no_license | package com.mishkapp.minecraft.plugins.squarekit.utils;
import org.spongepowered.api.entity.Entity;
import org.spongepowered.api.event.cause.entity.damage.DamageTypes;
import org.spongepowered.api.event.cause.entity.damage.source.DamageSource;
import org.spongepowered.api.event.cause.entity.damage.source.EntityDamageS... | true |
5183a9628b63b18e82d916c381b4c86043a08c2f | Java | msallam64/MoviesApp2 | /app/src/main/java/com/example/task_2/Model/DataModel.java | UTF-8 | 1,327 | 2.3125 | 2 | [] | no_license | package com.example.task_2.Model;
import androidx.annotation.NonNull;
import androidx.room.ColumnInfo;
import androidx.room.Entity;
import androidx.room.PrimaryKey;
import com.google.gson.annotations.Expose;
import com.google.gson.annotations.SerializedName;
@Entity(tableName = "movielist")
public class DataModel {
... | true |
6e297ee87211eb7dc4d3b01f319849a004fb3dd7 | Java | eep60b/projects | /excel-file-manager/src/main/java/com/etlsolutions/excel/controller/SummaryCountController.java | UTF-8 | 2,214 | 2.234375 | 2 | [] | no_license | package com.etlsolutions.excel.controller;
import com.etlsolutions.jlrmena.tests.excel.DataRow;
import com.etlsolutions.jlrmena.tests.excel.ExcelUtils;
import com.etlsolutions.tests.excel.datatable.LazyDqDataModel;
import java.io.Serializable;
import java.util.*;
import javax.annotation.PostConstruct;
import j... | true |
49aeb9ecba94091d8736787c56846fe1f4e2aebc | Java | malandaj/8Reinas | /Principal.java | UTF-8 | 5,128 | 2.984375 | 3 | [] | no_license | import javax.swing.JOptionPane;
import java.util.Comparator;
import java.util.Arrays;
import java.util.Random;
public class Principal {
static int nComparaciones = 0;
private static Object resizeArray (Object oldArray, int newSize) {
int oldSize = java.lang.reflect.Array.getLength(oldArray);
Class elementType ... | true |
a1fd3fb3f0c7295942e97a80a0d048fb4bd19f05 | Java | guguguray/CourseJava | /CH13/src/ch13_02/Ch13_02.java | BIG5 | 1,339 | 4.125 | 4 | [] | no_license | // @ Runnable إ߰
package ch13_02;
// إ߹@ Runnable lO CAddThread
class CAddThread implements Runnable
{
private String thread_name;
private int num;
// إߦӰѼƪOغcl
CAddThread(String name, int n)
{
thread_name = name;
num = n;
}
//@ Run() k
public void run()
{
int sum1=0, sum2;
//֥[ nA@
for (int... | true |
663d1b7fd561a458dc292de41e9e5977c44683b7 | Java | Integrative-Transcriptomics/Mayday-level2 | /src/main/java/mayday/vis3d/utilities/Camera2D.java | UTF-8 | 3,266 | 2.59375 | 3 | [] | no_license | package mayday.vis3d.utilities;
import java.awt.Component;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;
import java.awt.event.MouseMotionListener;
import java.awt.event.MouseWheelEvent;
import java.awt.event.MouseWheelListener;
import java.awt.geom.Point2D;
import com.jogamp.opengl.GL2;
impo... | true |
a33b184f16e350d3e5bd01248a642328d9efc84f | Java | qianc62/BePT | /code/org/processmining/analysis/sltl/SLTLPlugin.java | UTF-8 | 1,859 | 1.96875 | 2 | [] | no_license | /***********************************************************
* This software is part of the ProM package *
* http://www.processmining.org/ *
* *
* Copyright (c) 2003-2006 TU/e Eindhoven *
* ... | true |
c68a5aa43f3b3fd66a78e3c26aa9f174d03bcb19 | Java | Jingle-seven/demos | /jingle-server/src/main/java/xz/idao/provider/BaseSqlProvider.java | UTF-8 | 1,678 | 2.1875 | 2 | [] | no_license | package xz.idao.provider;
import org.apache.ibatis.jdbc.SQL;
import java.util.Map;
/**
* Created by Jinhua on 2017/6/14 17:04.
*/
public class BaseSqlProvider {
public String findIn(Map<String, Object> para) {
String s = new SQL()
.SELECT("*")
.FROM(para.get("t").toString())
.WHERE(String.forma... | true |
18265fd7d9101965c1b3028b94df1f3cc0257650 | Java | saeedcops/Sofra | /app/src/main/java/com/cops/sofra/ui/auth/userAuthCycle/ForgetPasswordFragment.java | UTF-8 | 4,878 | 1.945313 | 2 | [] | no_license | package com.cops.sofra.ui.auth.userAuthCycle;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Toast;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.databinding.DataBindingUtil;
import... | true |
2e813a3bb78edf4eb4e3e9de5b1d03a8bec9ee0f | Java | nav99/ProgrammaticApproch | /app1/src/com/string/Palindrom.java | UTF-8 | 585 | 3.734375 | 4 | [] | no_license | package com.string;
public class Palindrom {
public static void main(String[] args) {
String str ="ab cd,ef g::g fe,,,, #dc @bA";
String s1 = str.replaceAll("[, : # @]","").toLowerCase();
System.out.println(s1);
if(isPalindrome(s1))
{
System.out.println("number is palindromee");
}
else
Syst... | true |
a809c6592bf399210e55ea268d6e43dae0d5cc79 | Java | kutayzorlu/eagledns | /StandardUtils/src/se/unlogic/standardutils/exec/StreamHandler.java | UTF-8 | 314 | 2.40625 | 2 | [] | no_license | package se.unlogic.standardutils.exec;
import java.io.InputStream;
/**
* Abstract class for handling output from {@link InputStream}'s.<p>
*
* @author Robert "Unlogic" Olofsson (unlogic@unlogic.se)
*
*/
public abstract class StreamHandler extends Thread{
public abstract void setIs(InputStream is);... | true |
727259b0d29c4f9def9a80459ac080416a16a849 | Java | srijan-singh/CodeChef | /Beginner/Program Your Own CALCULATOR (URCALC)/calculator.java | UTF-8 | 814 | 3.484375 | 3 | [
"Apache-2.0"
] | permissive | import java.util.*;
import java.lang.*;
import java.io.*;
class Codechef {
public static void main (String[] args) throws java.lang.Exception {
Scanner scan = new Scanner(System.in);
int A = scan.nextInt();
int B = scan.nextInt();
char C = scan.next().charAt(0);
switch (C){
... | true |
f9fd6597cea03cd1b7cddb84d89ebf2ff3596cc4 | Java | andreiaskoda/bomberman | /Bomberman-core/src/com/bomber/entities/Player.java | UTF-8 | 5,857 | 2.859375 | 3 | [] | no_license | package com.bomber.entities;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.TextureRegion;
import com.badlogic.gdx.math.Vector2;
import com.badlogic.gdx.physics.box2d.Body;
import com.bomber.Game;
import handlers.GameKeys;
public class Player extends B2DSprite {
private ... | true |
0f7dd6aed486c321b681a8cf93c91a7841ceaf76 | Java | ruivale/Java | /JDK1.8Examples/src/exp/swing/tooltips/changinginallswing/DemoFrame.java | UTF-8 | 1,166 | 3.265625 | 3 | [] | no_license | package exp.swing.tooltips.changinginallswing;
import javax.swing.*;
import javax.swing.text.*;
import java.awt.*;
import java.awt.event.*;
/**
* DemoFrame.java
* This test frame is to demonstrate chnaging of tooltip background
*
* @author Rahul Sapkal(rahul@javareference.com)
*/
public class DemoFrame
ext... | true |
13ab350ba80e1c55d3b7617eb547d0e22178aaae | Java | ivanovamilena1979/LessonArraysPart2 | /src/com/company/Array2Rows4Columns.java | UTF-8 | 709 | 3.578125 | 4 | [] | no_license | package com.company;
import java.util.Arrays;
import java.util.Scanner;
public class Array2Rows4Columns {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
double[][] numbers = new double[2][4];
for (int i = 0; i < 2; i++) {
for (int j = 0; j < 4; j+... | true |
5e50a8192a80516c14eb9965dc876230e2ee4a35 | Java | zhangpanqin/fly-jdk8 | /src/main/java/java/nio/channels/SelectableChannel.java | UTF-8 | 3,522 | 2.765625 | 3 | [] | no_license | package java.nio.channels;
import java.io.IOException;
import java.nio.channels.spi.AbstractInterruptibleChannel;
import java.nio.channels.spi.SelectorProvider;
/**
* SelectableChannel 可以并发在多线程使用.
* SelectableChannel 只能注册一次 Selector,并且将 SelectableChannel 设置为非阻塞 io 模式效率会更好,当 io 没有数据的时候不会阻塞等待,而是返回没有读取到数据
* Selectio... | true |
4f97583cc2d2e35c9d65073bf397761ee799ccb8 | Java | Geekologyir/Parvaneh | /app/src/main/java/ir/geek/parvaneh/DatabaseHelper.java | UTF-8 | 14,293 | 1.789063 | 2 | [] | no_license | package ir.geek.parvaneh;
import android.content.ContentValues;
import android.content.Context;
import android.content.SharedPreferences;
import android.database.Cursor;
import android.database.SQLException;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;
import android.... | true |
cbcda88c33306c0355e710a707eab3e7254e47ca | Java | MuharremOkutan/JForex-2 | /jforex/trades/flat/AbstractMeanReversionSetup.java | UTF-8 | 6,810 | 2.125 | 2 | [] | no_license | package jforex.trades.flat;
import java.util.List;
import java.util.Map;
import com.dukascopy.api.IBar;
import com.dukascopy.api.IContext;
import com.dukascopy.api.IEngine;
import com.dukascopy.api.IOrder;
import com.dukascopy.api.Instrument;
import com.dukascopy.api.JFException;
import com.dukascopy.api.Period;
imp... | true |
9e9ec17f74c50dd97e1726ad539a86db3f2dbc36 | Java | tangwwk/Gof-DesignPatterns | /src/com/behavioral/strategy/Context.java | UTF-8 | 280 | 2.5625 | 3 | [] | no_license | package com.behavioral.strategy;
/**
* Created by doushuqi on 15/4/13.
*/
public class Context {
Strategy strategy;
public Context(Strategy strategy) {
this.strategy = strategy;
}
public void algorithm() {
strategy.orderAlgorithmic();
}
}
| true |