text
stringlengths
10
2.72M
package com.atguigu.java4; import org.junit.Test; /* finally : 1.finally中的代码一定会执行。 2.就算在try和catch中有return,那么finally中的代码也一定会执行。 */ public class FinallyTest { @Test public void test2(){ System.out.println(getNumber());//20 System.out.println("----------------------------------"); System.out.printl...
package com.equipo12.retobc.model.balance; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Data; import lombok.NoArgsConstructor; @Data @Builder(toBuilder = true) @AllArgsConstructor @NoArgsConstructor public class BalancesRS { private float available; private float availableOverdraftBalance...
package nl.esciencecenter.newsreader.hbase; import com.google.common.collect.Iterators; import org.apache.hadoop.hbase.Cell; import org.apache.hadoop.hbase.CellUtil; import org.apache.hadoop.hbase.KeyValue; import org.apache.hadoop.hbase.client.HTable; import org.apache.hadoop.hbase.client.Result; import org.apache.ha...
/* * 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 hotels; import javax.swing.table.DefaultTableModel; /** * * @author Nyagritin */ public class VilaRosaStock extends javax....
package sign.com.biz.base.service; import tk.mybatis.mapper.entity.Example; import java.util.List; /** * create by luolong on 2018/5/12 */ public interface BaseService<T> { //通过id查询对象 T selectById(Object id); //增加 int save(T t); //删除 int delete(T t); //根据主键修改对象的值 in...
import java.util.ArrayList; import java.util.List; public class BubbleSort<T extends Comparable> implements Sort<T> { private List<T> list; public BubbleSort(List<T> list) { this.list = new ArrayList<>(list); } @Override public List<T> getList() { return list; } @Overrid...
package com.example.htw.currencyconverter; import android.app.Application; import com.example.htw.currencyconverter.scopes.modules.PlatformModule; import com.example.htw.currencyconverter.scopes.components.AppComponent; import com.example.htw.currencyconverter.scopes.components.DaggerAppComponent; public class Curre...
/* Author: Arkadiusz Galas Date: 1 JUN 2016 ID: 26777 Name: Mr. Ant & His Problem */ /** MrAnt class is a solution of Mr. Ant & His Problem problem on * http://www.spoj.com/problems/ANTP/ */ import java.io.BufferedReader; import java.io.InputStreamReader; import java.io.IOException; import...
package ChatClient; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.net.Socket; import java.util.Scanner; public class ChatClient implements Runnable { private Socket socket; private boolean isAlive = true; private OutputStream outputStream = null; priv...
package com.example.service; import java.util.List; import com.example.dao.ImageDao; import com.example.dao.ImageDaoImpl; import com.example.model.image; public class ImageServiceImpl implements ImageService { private ImageDao img; { img=new ImageDaoImpl(); } public void createRecord(String imageId, String im...
/* * 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.exerciseSpringBoot.crudBootstrap.entities; import java.io.Serializable; import java.util.List; import javax.persistence.Ba...
package com.designurway.idlidosa.ui.home_page.fragments; import android.os.Bundle; import androidx.annotation.NonNull; import androidx.navigation.NavDirections; import com.designurway.idlidosa.HomeNavGraphDirections; import com.designurway.idlidosa.R; import java.lang.IllegalArgumentException; import java.lang.Object;...
package com.human.ex; public class quiz0228_03 { public static void main(String[] args) { java.util.Scanner sc = new java.util.Scanner(System.in); System.out.print("정수 입력 : "); int n = Integer.parseInt(sc.nextLine()); switch (n % 3) { case 0: System.out.println("거짓"); break; default...
package com.bloodl1nez.analytics.vk.api.likes; import com.bloodl1nez.analytics.vk.api.RequestParameters; import com.bloodl1nez.analytics.vk.api.VkAPIConfig; import com.bloodl1nez.analytics.vk.api.VkRequestManager; import org.json.JSONArray; import org.springframework.beans.factory.annotation.Autowired; import org.spri...
public class ConstructStringfromBinaryTree { /** * Input: Binary tree: [1,2,3,4] 1 / \ 2 3 / 4 Output: "1(2(4))(3)" Explanation: Originallay it needs to be "1(2(4)())(3()())", but you need to omit all the unnecessary empty parenthesis pairs. And it will be "1(2(4))(3...
package tests; import java.io.*; import java.util.*; /** * Created by Gauthier on 13/03/2017. */ public class EcrireData{ public static void main(String[] args) { FileWriter flot; PrintWriter flotFiltre; File chemin; String nomChemin = args[0]; Random r = new Random(); ...
/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package projetobanco; import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.SQLException; import java.util.ArrayList; /** * * @author Codification *...
package algorithms.sorting.compare; import algorithms.sorting.SelectionSort; import algorithms.sorting.ShellSort; import algorithms.sorting.heap.HeapSortFactory; import algorithms.sorting.insertion.InsertionSort; import algorithms.sorting.merge.CopyOnceMergeSort; import algorithms.sorting.merge.InsertionMergeSort; imp...
/* * 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.infohold.bdrp.authority.dao; import java.util.List; import com.infohold.bdrp.authority.model.AuthResource; import com.infohold.bdrp.authority.model.AuthRole; import com.infohold.bdrp.authority.model.AuthUser; public interface AuthorityDao<T extends AuthUser,K extends AuthRole> { public List<T> findAut...
package Main; import java.util.Scanner; /** * Created by Samarth on 5/30/16. */ public class SherlockAndSquares { public static void main(String[] args) { Scanner in = new Scanner(System.in); int t = in.nextInt(); for(int a0 = 0; a0 < t; a0++){ int f = in.nextInt(); ...
package ua.siemens.dbtool.service.impl; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.dao.DataIntegrityViolationException; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import ua.siemens.dbtool.dao.WorkPackage...
package com.sankalpa.bigdata.hdfs.client; import java.io.BufferedInputStream; import java.io.BufferedOutputStream; import java.io.File; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import org.apache.hadoop.conf.Co...
package Study5; public class S1AbsImpl implements S1Abs { @Override public void methodAbs1() { System.out.println("1"); } @Override public void methodAbs2() { System.out.println("2"); } @Override public void methodAbs3() { System.out.println("3"); } }
package com.github.mobile.ui.repo; import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.view.View; import android.widget.ListView; import com.github.kevinsawicki.wishlist.SingleTypeAdapter; import com.github.mobile.R; import com.github.mobile.ui.PagedItemFragment; ...
package project2; import java.sql.Connection; import java.sql.DriverManager; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.Statement; import java.util.Scanner; public class JdbcDemo { public static void main(String args[]) { try { Class.forName("com.mysql.jdbc.Driver"); Conn...
package com.espian.showcaseview.targets; import android.graphics.Point; public interface Target { public Point getPoint(); }
package ru.job4j.control; import org.junit.Test; import static org.junit.Assert.assertEquals; /** * Класс BalancerSemaphoreTest иллюстрирует работу класса java.util.concurrent.Semaphore. * * @author Gureyev Ilya (mailto:ill-jah@yandex.ru) * @version 1 * @since 2017-09-01 */ public class BalancerSemaphoreTest { ...
package 多线程.同步; /** * Created by 陆英杰 * 2018/9/7 10:31 */ public class 同步代码块 { public static void main(String[] args) { Runnable runnable=new Thread1();//new 一个可以被线程运行的类型,因为这个类实现了Runnable接口 Thread thread1=new Thread(runnable,"线程1");//让thread1线程运行runnable类中的run方法 Thread thread2=new Threa...
package com.nps.hellow.radar; import android.content.Context; import android.content.res.Resources; import android.graphics.Canvas; import android.graphics.Paint; import android.graphics.Path; import android.os.SystemClock; import android.util.AttributeSet; import android.view.View; import com.nps.hellow.R; /** * ...
package org.foolip.mushup; import org.musicbrainz.model.*; import org.neo4j.api.core.Node; import org.neo4j.api.core.Relationship; import org.neo4j.api.core.Direction; import org.neo4j.util.index.IndexService; import java.util.*; public class MushArtist extends MushEntity implements Artist { private static final...
package model; import image.Image; import java.util.ArrayList; import java.util.List; import java.util.Optional; import image.Pixel; /** * This class represents a simple model of an image processing application. */ public class SimpleMultiLayerImageProcessingModel implements MultiLayerImageProcessingModel { prote...
package com.accolite.au.services.impl; import com.accolite.au.dto.CustomEntityNotFoundExceptionDTO; import com.accolite.au.dto.TrainingDTO; import com.accolite.au.embeddables.TrainingEmbeddableId; import com.accolite.au.mappers.TrainingMapper; import com.accolite.au.models.Training; import com.accolite.au.models.Sessi...
package org.bellatrix.services; import java.math.BigDecimal; import org.bellatrix.data.AccountView; import org.bellatrix.data.MemberView; import org.bellatrix.data.ResponseStatus; public class BalanceInquiryResponse { private String formattedBalance; private BigDecimal balance; private BigDecimal reservedAmount;...
package com.starfall.created.factory.simplefactory; /** * @project JavaProject * @package com.starfall.created.factory.simplefactory * @className ConcreteProductA * @author StarFall * @date 2019/4/1 23:09 * @description 2.1、具体产品角色A */ public class ConcreteProductA implements Product { @Override public void p...
package com.basicRest; import com.Files.Payload; import io.restassured.path.json.JsonPath; public class ComplexParse { public static void main(String[] args) { // TODO Auto-generated method stub JsonPath Jsp=new JsonPath(Payload.coursePrice()); //Print the number of course in the Json int count=Js...
package VendingMachine1; /** * Created by FLK on 4/8/18. */ public class SoldOutExcepton extends RuntimeException { private String message; public SoldOutExcepton(String string) { this.message = string; } @Override public String getMessage(){ return message; } }
package New.practice; import java.util.Scanner; public class LoopTest { public void firstLoop() { int i = 0, j = 0; while (true) { i++; System.out.println("i=" + i); while (true) { j++; System.out.println("j=" + j); if (j > 2) break; } j = 0; if (i > 3) br...
package com.connectthedots.util; import java.io.ByteArrayOutputStream; import java.io.IOException; import java.io.InputStream; import java.io.Reader; /** * utilities for dealing with bytes and streams. * */ public class Bytes { public static String readFully(Reader reader) throws IOException { if (reader == nul...
import java.awt.Color; import java.awt.Font; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.KeyEvent; import java.awt.event.KeyListener; import java.io.BufferedReader; import java.io.BufferedWriter; import java.io.File; import java.io.FileReader; import java...
package hu.lamsoft.hms.customer.persistence.customer.dao; import java.util.Date; import java.util.List; import org.springframework.stereotype.Repository; import hu.lamsoft.hms.common.persistence.dao.BaseDao; import hu.lamsoft.hms.customer.persistence.customer.entity.CustomerMeal; @Repository public interface Custom...
package com.alibaba.druid.bvt.pool; import java.sql.Connection; import java.util.Properties; import junit.framework.TestCase; import org.junit.Assert; import com.alibaba.druid.mock.MockConnection; import com.alibaba.druid.pool.DruidDataSource; import com.alibaba.druid.pool.DruidDataSourceFactory; public class Drui...
package com.javarush.task.task10.task1015; import java.util.ArrayList; /* Массив списков строк */ public class Solution { public static void main(String[] args) { ArrayList<String>[] arrayOfStringList = createList(); printList(arrayOfStringList); } public static ArrayList<String>[] crea...
package com.paydock.androidsdk.View; import com.paydock.androidsdk.IGetToken; import com.paydock.javasdk.Models.ExternalCheckoutRequestZipMoney; import com.paydock.javasdk.Services.Environment; public interface IZipMoneyInputForm { void getCheckoutToken(Environment environment, String publicKey, String gatewayID...
package nom.hhx.cache.factory; import java.util.Properties; import org.slf4j.Logger; import org.slf4j.LoggerFactory; public class CacheBuilder { private Properties properties; private final Logger logger = LoggerFactory.getLogger( CacheBuilder.class ); public static class Settings { ...
package com.example.sean.onedroid; import android.content.Intent; import android.os.Bundle; import android.support.v7.app.AppCompatActivity; import android.view.View; import android.widget.ExpandableListAdapter; import android.widget.ExpandableListView; import java.util.ArrayList; import java.util.HashMap; import jav...
import java.io.BufferedReader; import java.io.FileReader; import java.io.IOException; import java.util.ArrayList; import java.util.HashMap; /** * cd Desktop/ENDI-2020/ARTIF-INTEL/PA4-KNN-AUC/knn-pa4/java * * javac -d bin src/*.java * * * java -cp bin kNNPA4 ../datasets/sms/train.csv ../datasets/sms/dev.csv 10...
package com.frist_demo; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.WebElement; public class MainPage { private WebDriver driver; private WebElement userMenu; public MainPage(WebDriver dr){ this.driver=dr; this.userMenu = driver.findElement(B...
import java.util.*; class dist { private int feet,inch; void read(int f,int i) { feet=f; inch=i; if(inch>=12) { feet+=inch/12; inch=inch%12; } } void print() { System.out.println(feet+"'"+inch+"\""); } } class distance { public static void main(String args[]) { Scanner x=new Scanner(S...
package net.lantrack.framework.core.entity; import java.io.Serializable; /** * 专门用来存放key-value的,一般给下拉,单选,复选框用 * * @date 2019年3月7日 */ public class MapEntity implements Serializable{ /** * */ private static final long serialVersionUID = 1L; /** * key */ private String k; /** *...
package com.awakenguys.kmitl.ladkrabangcountry; import com.awakenguys.kmitl.ladkrabangcountry.model.Announce; import org.springframework.data.mongodb.repository.MongoRepository; import org.springframework.data.repository.query.Param; import org.springframework.data.rest.core.annotation.RepositoryRestResource; import ...
package com.jxtb.test.controller; import com.jxtb.test.entity.Test; import com.jxtb.test.service.ISessionService; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.RequestMapping; import javax.annotation.Resource; import javax.servlet.ServletException; import javax.servl...
package org.flowable.cloud.runtime.core.behavior.classdelegate; import java.util.List; import org.flowable.bpmn.model.MapExceptionEntry; import org.flowable.cloud.runtime.core.utils.NameUtil; import org.flowable.common.engine.api.delegate.Expression; import org.flowable.engine.impl.bpmn.helper.ClassDelegate; import o...
package com.cpg.BankPro.dao; import static org.junit.jupiter.api.Assertions.*; import org.junit.jupiter.api.Test; import com.cpg.BankPro.dto.Customerpojo; class CustomerDetailsImplTest { Customerpojo pojo=new Customerpojo(); CustomerDetailsImpl dao=new CustomerDetailsImpl(); @Test void te...
package pages; import org.openqa.selenium.By; import org.openqa.selenium.NoSuchElementException; import org.openqa.selenium.support.ui.Select; public class ManageSIUReferralUpdateScorePage extends BasePage { private By SIUSummaryTextLocator = By.id("CLM_SC_BO_0008_SIUSummary_10a"); private By fraudSummaryTa...
package com.ainory.kafka.streams.entity; import com.ainory.kafka.streams.util.JsonUtil; import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.time.DateFormatUtils; import java.io.Serializable; import java.text.DecimalFormat; import java.util.ArrayList; import java.util.DoubleSummaryStatistics; ...
package Problem_1074; import java.util.Scanner; public class Main { static int N, r, c; public static int pow2(int x) { return 1<<x; } public static int answer(int n, int x, int y) { if(n == 1) return 2*x+y; else { if(x < pow2(n-1)) { if( y < pow2(n-1)) { return answer(n-1, x, y...
package com.leviathan143.craftingutils.client.gui.ingredientList; import java.io.IOException; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiButton; import net.minecraft.client.gui.inventory.GuiContainer; import net.minecraft.item.ItemStack; import org.lwjgl.input.Keyboard; import com.lev...
package io.breen.socrates.test.logicly; import java.util.UUID; public abstract class Evaluatable extends LogiclyObject { public final Evaluatable inputs[]; public final Evaluatable outputs[]; public Evaluatable(UUID uuid, int numInputs, int numOutputs) { super(uuid); this.inputs = new E...
public class Library { private double runTime; private int songs; private Album[] albums; public Library() { albums = new Album[10]; runTime = 0; songs = 0; } public void update(){ runTime = 0; songs = 0; for (Album val : albums){ if ...
/* * Copyright 2002-2019 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...
// this is a placeholder/stub class public class Range { private String literal; public Range(String literal) { this.literal = literal; } }
/** * */ package org.qsos.test; import java.net.MalformedURLException; import java.net.URL; import java.util.List; import org.qsos.utils.ILibQSOS; import org.qsos.utils.LibQSOS; import org.qsos.utils.SimpleMenuEntry; import junit.framework.TestCase; /** * @author Arthur Clerfeuille <arthur.clerfeuille@atosorig...
package ecommercseSite.PageObject; import org.openqa.selenium.WebDriver; import org.openqa.selenium.WebElement; import org.openqa.selenium.support.FindBy; public class MyAccountPage { public WebDriver driver; @FindBy(xpath = "//*[@href='http://automationpractice.com/index.php?mylogout=']") public WebElement logoutBt...
package Recursion; import java.util.Scanner; public class Nto1 { static void print(int n){ System.out.println(n); if(n>1) print(n-1); } public static void main(String[] args) { Scanner in = new Scanner(System.in); System.out.println("Enter the value of n"); int n = in.nextInt(); print(n); in.cl...
package by.realovka.diploma.repository; import by.realovka.diploma.entity.Like; import org.springframework.data.jpa.repository.JpaRepository; import java.util.List; public interface LikeRepository extends JpaRepository<Like, Long> { List<Like> findByPostId(long id); }
package com.example.ComputerOnline.Buyers; import android.content.DialogInterface; import android.content.Intent; import android.support.annotation.NonNull; import android.support.v7.app.AlertDialog; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.view.View; import android.wid...
package com.test; import org.junit.Test; /** * @Description: Class类 * @auther: LB 2018/9/19 09:37 * @modify: LB 2018/9/19 09:37 */ public class ClassTest { @Test public void classtest(){ System.out.printf(ClassTest.class+""); System.out.printf(ClassTest.class.equals(new ClassTest().getCla...
/* * Copyright 2002-2021 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 dk.jrpe.monitor.db.datasource.inmemory; import dk.jrpe.monitor.db.inmemory.httpaccess.InMemoryDataBase; import dk.jrpe.monitor.db.datasource.HttpAccessDataSource; import dk.jrpe.monitor.db.httpaccess.to.HTTPAccessTO; import java.util.List; /** * Data source for the in memory database. * @author Jörgen Pers...
package com.project.daicuongbachkhoa; import androidx.appcompat.app.AppCompatActivity; import android.content.Intent; import android.os.Bundle; import com.project.daicuongbachkhoa.R; import com.project.daicuongbachkhoa.account.LoginUser; import com.project.daicuongbachkhoa.landingpage.LandingPage; import com.project...
import java.awt.*; import java.awt.event.*; class AEvent extends Frame implements ActionListener{ TextField tf; AEvent(){ //create components tf=new TextField(); tf.setBounds(60,50,170,20); Button b=new Button("click to check Even Handling"); b.setBounds(30,120,250,30); //register listener b.addActionListener(this);/...
package task; import java.io.Serializable; import java.util.Arrays; /** * Created by kleba on 15.03.2018. */ public class Line implements Serializable { private Point pointFirst; private Point pointSecond; public Line(Point pointsFirst,Point pointSecond) { this.pointFirst=pointsFirst; ...
/* * Copyright 2015 Benedikt Ritter * * 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 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 colorselector; import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.control.Slider; import j...
package com.test.base; /** * Given an array nums, we call (i, j) an important reverse pair if i < j and nums[i] > 2*nums[j]. * i < j 并且 num[i] > 2*num[j],就是成功的一对 * * You need to return the number of important reverse pairs in the given array. * 计算给的一个数组,有多少个这样的一对 * * @author YLine * * 2019年5月29日 下午1:04:26 ...
package com.distributie.utils; import java.util.List; import java.util.Locale; import android.content.Context; import android.location.Geocoder; import com.distributie.beans.Address; import com.google.android.gms.maps.model.LatLng; public class MapUtils { public static LatLng geocodeAddress(Address address, Conte...
/* * Created on 01/10/2008 * * To change the template for this generated file go to * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments */ package com.citibank.ods.modules.product.prodasset.action; import com.citibank.ods.common.action.BaseODSMovementDetailAction; import com.citibank....
package acueducto.domain; import java.util.Map; import java.util.HashMap; import java.util.Collection; /** * * @author Karla Salas M. | Leonardo Sanchez J. */ public interface EstacionRepository { /** * Insercion de un objeto Estacion. * @param est * @return */ public boolean insertEst...
package loredan13.hearth_server; import com.sun.net.httpserver.HttpServer; import loredan13.hearth_server.server.*; import java.io.IOException; import java.net.InetSocketAddress; /** * Created by loredan13 on 24.01.2015. */ public class Main { public static int PORT = 12592; public static boolean shutdownF...
package com.example.demoapp.Activities; import androidx.annotation.NonNull; import androidx.appcompat.app.AppCompatActivity; import android.app.Dialog; import android.graphics.Color; import android.graphics.drawable.ColorDrawable; import android.os.Bundle; import android.view.View; import android.view.WindowManager; ...
package dao; import java.sql.Connection; public abstract class DaoFactory { private Connection conn; public DaoFactory() { } public abstract ProductDAO getProductDAO(); public abstract Connection openConnection(); public abstract void closeConnection(Connection conn); }
package com.domineer.triplebro.mistakebook.activities; import android.app.Activity; import android.content.SharedPreferences; import android.os.Bundle; import android.view.View; import android.widget.ImageView; import android.widget.ListView; import android.widget.RelativeLayout; import android.widget.Toast; import c...
package com.utils; import java.io.BufferedReader; import java.io.File; import java.io.FileReader; import java.io.IOException; import java.io.PrintWriter; public class FileManager { public static void saveToFile(String file, String content){ try{ PrintWriter writer = new PrintWriter(file, "UTF-8"); write...
package eu.bittrade.steem.steemstats.entities; import java.util.Date; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.GenerationType; import javax.persistence.Id; import javax.persistence.Table; /** * @author <a href="http://steemit...
package digitalclock; import java.awt.*; import javax.swing.*; public class DigitalClock extends JFrame{ JLabel clock; Clock cl; public DigitalClock() { clock= new JLabel("Casio"); setTitle("Saranti's Clock"); setLayout(new FlowLayout()); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); add(clock); se...
/* * Copyright 2002-2022 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 CubeBase2; import java.util.LinkedList; import Helper.Answer; class FactorialHelper { // attention overflow public final static int Fsize = 18; public static int[] F = new int[Fsize]; public static int[][] C = new int[Fsize][Fsize]; static { F[1] = 1; for (int i =...
package com.szhrnet.taoqiapp.mvp.api.response; /** * <pre> * author: MakeCodeFly * desc : PageListModel类 * email:15695947865@139.com * </pre> */ @SuppressWarnings({"WeakerAccess", "unused"}) public class PageListModel<T> { private boolean is_last; private T list; public boolean is_las...
/* Created on Apr 14, 2007 * */ package com.citibank.ods.entity.pl.valueobject; import java.util.ArrayList; import java.util.Date; import java.util.List; import com.citibank.ods.entity.pl.TplRiskFamilyProdPlayerHistEntity; import com.citibank.ods.entity.pl.TplRiskFamilyProdPlayerMovEntity; /** * @aut...
import javax.sound.midi.*; import java.io.*; import javax.swing.*; import java.awt.*; class MyDrawPanel_M extends JPanel implements ControllerEventListener{ boolean msg = false; public void controlChange(ShortMessage event){ msg = true; repaint(); } public void paintComponent(Graphics g){ if(msg){ ...
package io.t99.philesd.locations; import java.util.HashMap; public class LocationManager { private static HashMap<String, Location> locations = new HashMap<>(); public static void register(String name, Location location) { locations.put(name, location); } public static Location get(String name) { ...
package nowcoder; import java.util.*; public class Easy { /** * 反转字符串 * @param str string字符串 * @return string字符串 */ public String solve (String str) { char[] ans = new char[str.length()]; for (int i = 0; i < ans.length; i++) { ans[i] = str.charAt(str.length()-...
package com.xinhua.api.domain.xtBean; import com.apsaras.aps.increment.domain.AbstractIncRequest; import java.io.Serializable; /** * Created by ning on 15/7/21. * 心跳交易 请求 */ public class XtRequest extends AbstractIncRequest implements Serializable { /** *银行代码 */ private String bankCode; /** ...
/* * Copyright (c) 2013-2014, Neuro4j.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...
package common.util.xml; import java.io.StringReader; import java.io.StringWriter; import java.lang.reflect.Field; import java.lang.reflect.Method; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; import ja...
package org.beanone.xlogger.mock; public class MockArg { private final String id = "1"; private final String attribute = "attribute"; public String getAttribute() { return this.attribute; } public String getId() { return this.id; } }
package org.gatein.wcm.performance; import java.io.File; import java.text.DecimalFormat; import java.util.List; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import javax.annotation.Resource; import junit.framework.Assert; import org.gatein.wcm.api.services.WCMContentService; i...
import java.util.LinkedList; import java.util.Queue; import java.util.Stack; class TreeTraversal { class TreeNode{ public TreeNode left; public TreeNode right; public int val; public TreeNode(int val){ this.val = val; } } public static void main(String[]...
package fr.skytasul.quests.options; import org.bukkit.entity.Player; import fr.skytasul.quests.QuestsConfiguration; import fr.skytasul.quests.api.options.OptionSet; import fr.skytasul.quests.api.options.QuestOptionString; import fr.skytasul.quests.utils.Lang; import fr.skytasul.quests.utils.XMaterial; publ...