text stringlengths 10 2.72M |
|---|
/*
Count the number of prime numbers less than a non-negative number, n.
*/
public int countPrimes(int n) {
boolean[] isPrime = new boolean[n];
for (int i=2;i<n;i++){
isPrime[i]=true;
}
//mark off prime's multiples because they are not prime numbers
for (int i=2;i*i<n;i++){
... |
package com.jeffdisher.thinktank.crypto;
import java.security.InvalidKeyException;
import java.security.KeyFactory;
import java.security.KeyPair;
import java.security.KeyPairGenerator;
import java.security.NoSuchAlgorithmException;
import java.security.PrivateKey;
import java.security.PublicKey;
import java.security.S... |
package com.example.kuno.intentmultiex;
import android.app.Activity;
import android.os.Bundle;
/**
* Created by kuno on 2017-01-31.
*/
public class SettingsActivity extends Activity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setCont... |
package practica10.ejemplo4_Listener;
import org.testng.IInvokedMethod;
import org.testng.IInvokedMethodListener;
import org.testng.ITestResult;
//implementamos un interface de testNg
public class InvokedMethodListener implements IInvokedMethodListener{
@Override
public void beforeInvocation(IInvokedMethod method, ... |
package com.spreadtrum.android.eng;
import android.util.Log;
import java.io.ByteArrayOutputStream;
import java.io.DataOutputStream;
import java.io.IOException;
public class engfetch {
private int mSocketID = -1;
private int mType = 0;
private static native void disable_modemdebugpm(int i);
private s... |
package com.sun.xml.bind.v2.model.impl;
import java.lang.reflect.Field;
import java.lang.reflect.Method;
import java.lang.reflect.Type;
/**
* @author Kohsuke Kawaguchi
*/
final class RuntimeEnumConstantImpl extends EnumConstantImpl<Type,Class,Field,Method> {
public RuntimeEnumConstantImpl(
RuntimeEnumLe... |
public enum FurnitureEnum {
DOOR, SWINDOW, DWINDOW, FOURPTABLE, SIXPTABLE, EIGHTPTABLE, CHAIR, BIGCHAIR,
SMALLBENCH, BIGBENCH ,LOWILUM, MEDILUM, STRONGILUM;
public int getWidth(FurnitureEnum furEnum) {
switch (furEnum) {
case FOURPTABLE:
return 34;
case SIXP... |
package cs261_project.controller;
import java.net.URLEncoder;
import java.util.Map;
import javax.annotation.Nullable;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import org.eclipse.jetty.util.UrlEncoded;
import org.springframework.beans.factory.annotation.Value;
import org.sp... |
package com.bestone.service;
import com.bestone.model.ArticleModel22;
import com.bestone.model.UserArticle22;
import java.util.List;
public interface ArticleService22 {
//create shequ article
void save(ArticleModel22 article22);
//find all shequ articles
List<UserArticle22> findAllShequArticle();
... |
// 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.neuron.mytelkom;
import android.view.View;
import android.widget.AdapterView;
import com.neuron.mytelkom.model.ConferenceAttendees;
... |
package be.odisee.pajotter.controller;
import be.odisee.pajotter.domain.*;
import be.odisee.pajotter.service.PajottersSessieService;
import be.odisee.pajotter.utilities.RolNotFoundException;
import java.util.List;
import javax.validation.Valid;
import org.springframework.beans.factory.annotation.Autowired;
import o... |
package shulei.july24;
import java.awt.BorderLayout;
import java.awt.DisplayMode;
import java.awt.GraphicsDevice;
import java.awt.GraphicsEnvironment;
import java.awt.event.KeyEvent;
import java.awt.event.KeyListener;
import java.security.Key;
import javax.swing.JFrame;
import javax.swing.border.Border;
public class... |
package android.support.v4.media;
import android.os.Bundle;
import android.support.annotation.RestrictTo;
import android.support.annotation.RestrictTo.Scope;
@RestrictTo({Scope.LIBRARY_GROUP})
public class MediaBrowserCompatUtils {
public static boolean areSameOptions(Bundle bundle, Bundle bundle2) {
bool... |
/*
* 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 org.exist.xquery.modules.mpeg7.x3d.helpers;
import java.io.BufferedInputStream;
import java.io.ByteArrayOutputStream;
import j... |
package com.wmc.springboot.service;
import org.springframework.stereotype.Service;
/**
* @author: WangMC
* @date: 2019/7/10 18:19
* @description:
*/
@Service
public class AsyncService {
public void hello(){
System.out.println("hello");
}
}
|
/* PROBLEM: Calculate factorial of number */
public class Factorial {
//Uses recursion due to nature
public static int fact(int i) {
if (i <= 1) return 1; //0! = 1! = 1
else return i * fact(i-1);
}
public static void main(String[] args) {
System.out.println(fact(5));
}
} |
package mikfuans.security.dao;
import mikfuans.security.bean.SysRolePermission;
import mikfuans.security.bean.SysRolePermissionCriteria;
import org.apache.ibatis.annotations.*;
import org.apache.ibatis.type.JdbcType;
import java.util.List;
@Mapper
public interface SysRolePermissionMapper {
@SelectProvider(type=... |
package jianzhioffer;
import jianzhioffer.utils.ListNode;
/**
* @ClassName : Solution23
* @Description : 链表中环的入口节点
第一步:判断链表中是否有环
// 定义两个速度不同的指针,慢的一次一步,快的一次两步,如果有环,走得快的指针一定能追上走得慢的指针,如果走得快的指针到达链表的末尾时还没追上,则意味着没有环。
// 第3步:找到环的出入口
// 定义两个指针,若环的节点数为n,则指针P1先行n步时,P2指针开始以相同的速度移动,此时P1已经到达环的入口了。
// 第2步:得到环的节点数
// ... |
package com.globallogic.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import org.springframework.security.core.GrantedAuthority;
@Entity
@Table(name="ROLE_DETAILS")
public class RoleDetails implements GrantedAuthority {
private... |
package br.mg.puc.sica.evento.evento.model.response;
import br.mg.puc.sica.evento.evento.model.Sensor;
import java.util.List;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
@Getter
@Setter
@Builder
@AllArgsConstructor
@NoArgsConstr... |
package MachineLearning;
import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
public class SameNumberofLines {
public static void main(String args[]) throws IOException{
String type = args[0];
String outdir = "/home/c-tyabe/Data/MLResults_"+type+"13/";
String outdir3 = outdi... |
import java.util.*;
public class GraphMatrix {
//produces an adjacency matrix to implement a graph
private static int V; //number of vertices in the graph
private static List<int[]> adjacencyMatrix = new ArrayList<int[]>(V);
GraphMatrix(int VSize) {
V = VSize;
for (int i = 0; i < V; i++) {
adjacencyM... |
/*
* 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 tokomainankita;
/**
*
* @author windows10
*/
public class Barang {
private int id_barang;
private int id_supplier;
... |
package in.msmartpay.agent.myWallet;
class BalHistoryModel {
public String dateBal;
public String timeBal;
public String modeBal;
public String amountBal;
public String statusBal;
public String refIdBal;
public String getDateBal() {
return dateBal;
}
public void setDate... |
package defenseSystem_levels;
import defenseSystem.ID;
import java.awt.Color;
import java.awt.Graphics2D;
import java.awt.event.MouseEvent;
import java.awt.image.ImageObserver;
import java.util.LinkedList;
import java.util.Random;
import java.util.Timer;
import java.util.TimerTask;
import javax.swing.JPanel;
import... |
/*
* Copyright (c) 2014 ICM Uniwersytet Warszawski All rights reserved.
* See LICENCE file for licensing information.
*
* Created on 18 jan 2015
* Author: P. Piernik
*/
/**
* Common code related to confirmation subsystem
* @author P. Piernik
*/
package pl.edu.icm.unity.confirmations; |
package com.design.pattern.factoryDemo;
/**
* 抽象工厂类
* Created by zhouliang on 2017/10/19.
*/
public abstract class Factory {
/*创建方法*/
public abstract <T extends AudiCar> T creatAudiCar(Class<T> clz);
}
|
/**
*
*/
package de.calendarmodule.calendar.client.model;
import de.smartmirror.smf.client.model.Model;
/**
* @author julianschultehullern
*
*/
public interface CalendarModel extends Model {
}
|
/*
* 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 br.edu.ifrs.mostra.models;
import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
impor... |
package com.lenovohit.hwe.treat.service.impl;
import java.util.Map;
import org.springframework.stereotype.Service;
import com.lenovohit.hwe.treat.dto.GenericRestDto;
import com.lenovohit.hwe.treat.model.Profile;
import com.lenovohit.hwe.treat.service.HisProfileService;
import com.lenovohit.hwe.treat.transfer.RestEnt... |
package com.getkhaki.api.bff.domain.persistence;
import com.getkhaki.api.bff.domain.models.EmployeeDm;
import com.getkhaki.api.bff.domain.models.EmployeeWithStatisticsDm;
import com.getkhaki.api.bff.persistence.models.EmployeeDao;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Page... |
package me.libraryaddict.disguise.disguisetypes.watchers;
import org.bukkit.inventory.ItemStack;
import me.libraryaddict.disguise.disguisetypes.Disguise;
import me.libraryaddict.disguise.disguisetypes.MetaIndex;
import me.libraryaddict.disguise.disguisetypes.FlagWatcher;
public class DroppedItemWatcher exten... |
/**
* Copyright (C) 2015-2016, Zhichun Wu
*
* 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 Li... |
package Testabcd;
import org.openqa.selenium.By;
public class ShoppingCartPage extends Utils
{
private By _shoppingCart = By.xpath("//div[@class='page-title']");
//Asserting Shopping cart page
public void userShoulcSeeAllProductAddToCart()
{
Utils.assertMessagetext(_shoppingCart);
}
... |
package com.san.fieldType;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annot... |
package BoardDAO;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.List;
import BoardDTO.BoardDTO;
public class BoardDAO {
private Connection getConnectio... |
package test.thread;
public class MyRunnable implements Runnable {
private int i;
public MyRunnable(int i) {
this.i = i;
}
@Override
public void run(){
for(i=0;i<100;i++){
System.out.println(Thread.currentThread().getName() + " " + i);
}
}
}
|
package com.meehoo.biz.core.basic.handler;
import com.meehoo.biz.common.util.BaseUtil;
import com.meehoo.biz.common.util.DateUtil;
import com.meehoo.biz.core.basic.exception.SearchConditionException;
import com.meehoo.biz.core.basic.param.SearchCondition;
import org.hibernate.criterion.*;
import org.springframework.st... |
package com.redsun.platf.entity.sys;
// default package
// Generated 2010/8/12 下午 05:52:38 by Hibernate Tools 3.3.0.GA
import java.util.Date;
import javax.persistence.Entity;
import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import com.redsun.platf.entity.BaseEntity... |
package proghf.view;
import javafx.fxml.FXMLLoader;
import proghf.Main;
import proghf.controller.TableColumnController;
import proghf.model.Label;
import proghf.model.Table;
import java.io.IOException;
/**
* Táblaoszlop nézete
*/
public class TableColumnView extends View {
/**
* Az oszlophoz tartozó tábl... |
package ui;
/**
* 用户信息修改
*/
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JOptionPane;
import javax.swing.JPanel;
import javax.swing.JTextField;
import Dao.Impl.UserDaoImpl;
import entity.... |
package com.fuzz.android.location;
import android.location.Location;
public interface LocationApplication {
public Location getCurrentLocation();
public void startLocation();
public void endLocation();
public boolean oneTime();
}
|
import java.util.*;
class FiveArray
{
public static void main(String args[])
{
Scanner sc=new Scanner(System.in);
int i=0;
System.out.println("Enter Array Size :");
int size=sc.nextInt();
int Arr[]=new int[size];
System.out.println("Enter Array Elements :");
for(i=0;i<Arr.length;i++)
{
System... |
package dev.mher.taskhunter.models.misc.task;
import lombok.Getter;
import lombok.Setter;
/**
* User: MheR
* Date: 12/5/19.
* Time: 2:51 PM.
* Project: taskhunter.
* Package: dev.mher.taskhunter.models.misc.task.
*/
@Getter
@Setter
public class CreateTaskParams {
private Integer projectId;
private Inte... |
package com.controller;
import java.sql.Timestamp;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import javax.annotation.Resource;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.R... |
/*
* 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.mycompany.arbol_activacion.abs.instruccion;
import com.mycompany.arbol_activacion.abs.Arbol;
import com.mycompany.arbol_ac... |
package com.fzw.education.activity;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import com.fzw.education.R;
import com.fzw.education.R.id;
import com.fzw.education.R.layout;
import com.fzw.education.R.menu;
import com.fzw.education.db.ImportDatabase;
import android.app.ActionBar;
imp... |
import java.util.Scanner;
public class HelloWorld{
// 1、变量,常量
public static void values(){
System.out.println("常量 变量");
int a = 1; // 变量
final double pi = 3.1415926; // 常量
System.out.println(a + "\n" + pi);
}
// 2、字符串类型
public void string_method(){
S... |
package org.point85.domain.opc.da;
import java.util.Collection;
import java.util.LinkedList;
import java.util.List;
import java.util.Objects;
import org.openscada.opc.dcom.da.PropertyDescription;
import org.openscada.opc.dcom.da.impl.OPCItemProperties;
import org.openscada.opc.lib.da.browser.Leaf;
public class OpcDa... |
package plugins.fmp.capillarytrack;
import java.awt.GridLayout;
import java.beans.PropertyChangeEvent;
import java.beans.PropertyChangeListener;
import javax.swing.JPanel;
import javax.swing.JTabbedPane;
import icy.gui.util.GuiUtil;
import plugins.fmp.fmpTools.EnumStatusPane;
public class ResultsPane extends JPanel... |
/*
* Copyright 2002-2023 the original author or authors.
*
* 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 a... |
package com.sohu.live56.view.util;
import android.content.Context;
import android.util.AttributeSet;
import android.view.View;
import android.view.ViewGroup;
import android.widget.CheckBox;
import android.widget.CompoundButton;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.... |
package com.mmm.service.advices;
import org.springframework.aop.MethodBeforeAdvice;
import java.lang.reflect.Method;
/**
* 前置通知
*/
public class BeforeAdvice implements MethodBeforeAdvice {
/**
* 在目标方法执行之前
* @param method 目标方法
* @param objects 目标方法参数列表
* @param o 目标对象
* @throws... |
package com.fubang.wanghong.model;
import com.fubang.wanghong.model.impl.ActorModelImpl;
import com.fubang.wanghong.model.impl.AnchorModelImpl;
import com.fubang.wanghong.model.impl.FavoriteModelImpl;
import com.fubang.wanghong.model.impl.FollowModelImpl;
import com.fubang.wanghong.model.impl.GiftTopModelImpl;
import ... |
package com.nikita.recipiesapp.views.steps;
import com.airbnb.epoxy.EpoxyAttribute;
import com.airbnb.epoxy.EpoxyModelWithHolder;
import com.nikita.recipiesapp.R;
import com.nikita.recipiesapp.common.models.Ingredient;
import com.nikita.recipiesapp.views.common.TextViewHolder;
class IngredientModel extends EpoxyMode... |
package com.gazlaws.codeboard.layout;
import com.gazlaws.codeboard.layout.builder.KeyInfo;
public class Key {
public Box box;
public KeyInfo info;
}
|
package com.as.boot.txffc.thread;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileInputStream;
import java.io.InputStreamReader;
import java.text.DecimalFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import com.as.boot.txffc.control... |
import java.util.*;
import java.lang.*;
class GFG
{
// Fucntion to calculate sum
public static int summation(int n)
{
int sum = 0;
for (int i = 1; i <= n; i++)
sum += (i * i);
return sum;
}
// Driver code
public static void main(String args[])
{
int n = 100;
System.out.prin... |
package org.example.codingtest.oneLevel;
public class IntegerSquare {
public static void main(String[] args) {
int n = 3;
long solution = solution(n);
System.out.println(solution);
}
public static long solution(long n) {
double sqrt = Math.sqrt(n);
String s = String... |
/**********************************************************************
Copyright (c) 2014 Baris ERGUN and others. 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://ww... |
package com.mkdutton.labfour;
import android.app.Notification;
import android.app.NotificationManager;
import android.app.PendingIntent;
import android.app.Service;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import andro... |
/**
* Graph search algorithms.
*/
package algopro.algo;
|
package com.digit88.interview;
/*
* Given an array find the pairs with the given target
*/
public class TwoSum {
}
|
package com.xinhua.api.osb;
import com.apsaras.hsf.common.Constants;
import com.apsaras.hsf.common.URL;
import com.apsaras.hsf.rpc.*;
import com.apsaras.hsf.rpc.protocol.AbstractInvoker;
import com.apsaras.hsf.rpc.protocol.AbstractProtocol;
import org.apache.cxf.bus.extension.ExtensionManagerBus;
import org.apache.cx... |
/**
*
*/
package com.jspmyadmin.app.database.trigger.controllers;
import java.sql.SQLException;
import com.jspmyadmin.app.common.logic.DataLogic;
import com.jspmyadmin.app.database.trigger.beans.TriggerBean;
import com.jspmyadmin.app.database.trigger.logic.TriggerLogic;
import com.jspmyadmin.framework.constants.Ap... |
package org.cryptable.asn1.runtime.ber;
import org.cryptable.asn1.runtime.ASN1Real;
import org.cryptable.asn1.runtime.exception.ASN1Exception;
import java.math.BigInteger;
import java.text.NumberFormat;
/**
* The BER implementation of ASN1 Real values
* Default will be binary encoding
*
* Created by david on 23/... |
package br.com.herculano.urlshortener.api.service;
import java.util.Optional;
import javax.persistence.EntityNotFoundException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import br.com.herculano.urlshortener.api.configuration.system_message.CommonMe... |
package video_storm;
import org.lwjgl.LWJGLException;
import org.lwjgl.input.Keyboard;
import org.lwjgl.opengl.Display;
import video_storm.input.KeyInput;
import video_storm.input.MouseInput;
public class MainTest {
public static void main( String[] args ) throws LWJGLException {
new Window(640,... |
package com.example.agustinuswidiantoro.icp_mobile.activity;
import android.app.ActionBar;
import android.app.ProgressDialog;
import android.content.Intent;
import android.os.AsyncTask;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.util.Log;
import android.view.View;
import ... |
package com.swapping.springcloud.ms.hystrix.turbine;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.circuitbreaker.EnableCircuitBreaker;
import org.springframework.cloud.client.discovery.EnableDiscoveryClie... |
package com.hackucla.chatbot;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
import retrofit2.Call;
import retrofit2.Callback;
import retrofit2.R... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package com.itcs.helpdesk.util;
import com.itcs.helpdesk.jsfcontrollers.util.ApplicationBean;
import com.itcs.helpdesk.jsfcontrollers.util.UserSessionBean;
import com.itcs.helpdesk.persistence.entities.Accion;
import co... |
package interfaces;
/**
* @author dylan
*
*/
public interface DrawAPI {
/**
* @param radius
* @param x
* @param y
*/
public void drawCircle(int radius, int x, int y);
}
|
package use_multi_thread;
/**
* 实现多线程法二:
* 实现 Runnable 接口
*/
public class MyRunnable implements Runnable {
private static int shareVar = 5; // 共享数据
private int var = 5; // 非共享数据,每个实例一份
@Override
synchronized public void run() {
shareVar--;
var--;
System.out... |
package generics;
import java.util.Collection;
import java.util.Map;
import java.util.Set;
/**
* Created by user on 05.12.16.
*/
public abstract class Machine <Key, Value> {
private Map<Key, Value> MAP = new Map<Key, Value>() {
@Override
public int size() {
return 0;
}
... |
package com.fanoi.ximi.modules;
import android.os.Bundle;
import android.support.v4.app.FragmentActivity;
import android.view.KeyEvent;
import android.widget.Toast;
import com.fanoi.ximi.GlobalApplication;
/**
* activity的base类,用于基本数据的初始化
*
* @author JetteZh
*/
public class BaseActivity extends FragmentActivity {... |
package com.zantong.mobilecttx.user.bean;
import com.zantong.mobilecttx.base.bean.Result;
/**
* Created by zhengyingbing on 16/6/1.
*/
public class VcodeResult extends Result {
private VcodeBean RspInfo;
public VcodeBean getRspInfo() {
return RspInfo;
}
public void setRspInfo(VcodeBean rs... |
package edu.ptc.salter.bella;
import edu.jenks.dist.ptc.*;
public class PhoneNumber implements PhoneNumberable {
String number = "";
String areaCode = "";
String prefix = "";
String lineNumber = "";
public static void main(String[] args) {
PhoneNumber tester = new PhoneNumber("1-800-111 6222");
Syst... |
package db.connection;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
public class DbConnection {
private static final String URL = "jdbc:mysql://localhost:3306/library";
private static String DB_NAME = "library";
private static final String USERNAME = "root";
pr... |
package com.auro.scholr.util.alert_dialog;
import android.app.Dialog;
import android.content.Context;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.Window;
import android.widget.ImageView;
import androidx.fragment.app.DialogFragment;
import com.auro.schol... |
package com.github.rosjava.android_apps.blind_guide.data_manager;
public interface dataLoader extends org.ros.internal.message.Message{
java.lang.String _TYPE = "com.github.rosjava.android_apps.blind_guide/data_manager/dataLoader";
java.lang.String _DEFINITION = "string a\n---\nstring result\n";
} |
import javax.sound.sampled.Line;
import java.awt.*;
public class Main {
public static void main(String[] args) {
//an example of using linear regression to predict hunting success in chimpanzee hunting parties depending on the number of chimps in the party
LinearRegression linreg = new LinearRegre... |
package be.vdab.teno.video.dao;
import be.vdab.teno.video.entities.IVerhuurbaar;
public interface IVerhuurbaarDao {
IVerhuurbaar findById(int id);
}
|
// Decompiled by Jad v1.5.7g. Copyright 2000 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/SiliconValley/Bridge/8617/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi
// Source File Name: Base64Encoder.java
package com.git.cloud.sys.tools;
import java.io.*;
import java.security... |
package io.ceph.rgw.client.model.admin;
import software.amazon.awssdk.core.SdkField;
import software.amazon.awssdk.core.SdkPojo;
import software.amazon.awssdk.core.protocol.MarshallLocation;
import software.amazon.awssdk.core.protocol.MarshallingType;
import software.amazon.awssdk.core.traits.LocationTrait;
import sof... |
package com.avishai.MyShas;
import android.content.Context;
import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;
import java.util.Map;
import java.util.Set;
/**
* A class that represent a file object
*/
public class Keystore {
private SharedPreferences SP;
... |
package com.example.adnan.inventoryapp;
import android.content.DialogInterface;
import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.support.v4.app.Fragment;
import android.support.v7.app.AlertDialog;
import android.util.Log;
import android.view.LayoutInflater;
import an... |
package com.karya.model;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
@Entity
@Table(name="bomtype001mb")
public class BomType001MB {
private static fin... |
package com.trump.auction.trade.vo;
import com.trump.auction.trade.model.AuctionRuleModel;
import com.trump.auction.trade.model.ProductInfo;
import com.trump.auction.trade.model.ProductPic;
import lombok.Data;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
/**... |
/*insertbcomm*/
import java.sql.*;
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
public class insertbcomm extends HttpServlet
{
PreparedStatement ps;
Connection c;
public void init(ServletConfig config)
{
}
public void doGet(HttpServletRequest req,HttpServletRespons... |
/* PROBLEM: Reverse a string in place. */
public class ReverseString {
/* The easiest option is just to create a new string,
then start from the end and add letters to the new string one at a
time. However, this takes O(n) space and thus is not in place.
Instead we could convert the string to char array, then ... |
package cn.com.xbed.common.source;
/**
* @Description:读写库的切换
* @author:Tom
* @create 2017-03-06 15:07
**/
public class DataSourceSwitcher {
/**
* 主库,读写库,只一个
*/
public static final String MASTER_DATA_SOURCE = "master";
/**
* 从库,只读库,可有多个
*/
public static final String[] SLAVE_DATA_... |
package cl.cehd.ocr.algorithm.processor;
import cl.cehd.ocr.algorithm.entity.AccountDigit;
import cl.cehd.ocr.algorithm.entity.DigitRepresentationDictionary;
import cl.cehd.ocr.algorithm.entity.IndividualDigitIdentifier;
import org.junit.Before;
import org.junit.Test;
import java.util.List;
import static cl.cehd.ocr... |
/*
* Copyright 2017 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applic... |
/*
* 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 fahrstuhlsimulator;
import java.util.ArrayList;
/**
*
* @author mex
*/
public class Etage implements tick {
protected... |
package myProject.second;
import java.awt.Graphics;
import java.awt.image.BufferedImage;
public class TileLevel1 {
public static TileLevel1[] tiles = new TileLevel1[24];
/*
public static Tile roadTile = new roadTile(0);
public static Tile grassTile = new grassTile(1);
public static Tile... |
package com.nick.java.game.runner;
import com.nick.java.game.items.Constants;
import com.nick.java.game.items.Control;
import com.nick.java.game.items.Box;
import javax.swing.*;
import java.applet.Applet;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event... |
package Lec_04_NestedConditionalStatements;
import java.util.Scanner;
public class Pro_04_04_NewHouse {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
System.out.print("Въведете вида на цветята: ");
String typeFlower = scanner.nextLine();
Syst... |
package org.aksw.autosparql.tbsl.algorithm.util;
import org.aksw.autosparql.commons.index.Indices;
import org.aksw.autosparql.tbsl.algorithm.search.BugfixedSolrIndex;
import org.aksw.autosparql.tbsl.algorithm.search.DbpediaFilter;
import org.aksw.autosparql.tbsl.algorithm.search.FilteredIndex;
import org.dllearner.com... |
import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;
public class Solution {
private static int maximumHourGlass(int[][] arr)
{
int top=0,mid=0,bottom=0,max=-99999;
for(int i=0;i<4;i++)
{
for(int j=0;j<4;j++)
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.