Java
wxg_wll
这个作者很懒,什么都没留下…
展开
-
Understand Spring Security Architecture and implement Spring Boot Security
In this tutorial we will be looking at how Spring Security works and its architecture. We will be creating a Spring Boot Project to expose two REST API’s研究Spring Security的工作方式及其架构/helloadmin/hellouserWe will then be implementing Spring Security such原创 2020-07-20 18:25:45 · 193 阅读 · 0 评论 -
Building a Hypermedia-Driven RESTful Web Service
Building a Hypermedia-Driven RESTful Web Service构建超媒体驱动的RESTful Web服务This guide walks you through the process of creating a “Hello, World” Hypermedia-driven REST web service with Spring.本指南将引导您完成使用Spring创建“Hello,World”超媒体驱动的REST Web服务的过程Hypermedia is a原创 2020-07-05 00:14:47 · 244 阅读 · 0 评论 -
Accessing data with MySQL
This guide walks you through the process of creating a Spring application connected to a MySQL Database (as opposed to an in-memory, embedded database, which most of the other guides and many sample applications use). It uses Spring Data JPA to access the原创 2020-07-03 23:59:02 · 1004 阅读 · 0 评论 -
Java TreeMap Tutorial with Examples-cnblog
Java TreeMap Tutorial with ExamplesJava TreeMap is a Red-Black tree based implementation of Java’s Map interface.Java TreeMap是Java Map接口的基于红黑树的实现The entries in a TreeMap are always sorted based on the natural ordering of the keys, or based on a custom原创 2020-07-02 16:44:04 · 220 阅读 · 1 评论 -
Java Palindrome Tutorials
Java Palindrome tutorial shows how to work with palindromes in Java.Java Palindrome教程展示了如何在Java中使用回文Palindrome is a word, number, phrase, or other sequence of characters which reads the same backward as forward, such as madam or racecar.回文报是一个单词,数字,短语或其原创 2020-07-02 14:41:58 · 280 阅读 · 0 评论 -
Java Consumer Functional Interface
Java Consumer tutorial shows how to work with the Consumer functional interface in Java.如何使用Java中的Consumer函数式接口ConsumerJava Consumer is a functional interface which represents an operation that accepts a single input argument and returns no result. Unli原创 2020-07-02 13:41:05 · 250 阅读 · 0 评论 -
Spring Boot, MySQL, JPA, Hibernate Restful CRUD API Tutorial
Spring Boot MySQL JPA Hibernate Restful CRUD API TutorialSpring Boot has taken Spring framework to the next level. It has drastically reduced the configuration and setup time required for spring projects.Spring Boot将Spring框架提升到了一个新的高度。它大大减少了Spring项目所需的配原创 2020-07-01 18:19:49 · 292 阅读 · 0 评论 -
Java and bitwise shift operators
Java >> and >>> bitwise shift operatorsIn programming, bitwise shift operators, >> means arithmetic right shift, >>> means logical right shift, the differences:在编程中,按位运算符,>>表示算数右移,>>>表示逻辑右移,其区别在于>>, it原创 2020-06-30 15:31:14 · 3811 阅读 · 0 评论 -
Java ArrayList Tutorial with Examples
ArrayList in Java is used to store dynamically sized collection of elements. Contrary to Arrays that are fixed in size, an ArrayList grows its size automatically when new elements are added to it.Java中的ArrayList用于存储动态调整大小的元素集合。与固定大小的数组相反,当向其添加新元素时,ArrayL.原创 2020-06-30 14:19:13 · 248 阅读 · 0 评论 -
Java HashMap
In this tutorial, we will learn about the Java HashMap class and its methods with the help of examples.The HashMap class of the Java collections framework provides the hash table implementation of the Map interface.Java集合框架的HashMap类提供Map接口的哈希表实现。Create原创 2020-06-28 15:40:41 · 169 阅读 · 0 评论 -
Java HashMap Tutorial with Examples
Java HashMap is a hash table based implementation of Java’s Map interface. A Map, as you might know, is a collection of key-value pairs. It maps keys to values.Java HashMap是基于哈希表的Java Map接口的实现。map是键值对的集合。它将映射到值。Following are few key points to note abou.原创 2020-06-28 14:27:31 · 199 阅读 · 0 评论 -
Java Convert String to Binary
This article shows you five examples to convert a string into a binary string representative or vice verse.本文向您展示了五个示例,这些示例将字符串转换为二进制字符串表示形式,反之亦然。Convert String to Binary – Integer.toBinaryStringConvert String to Binary – Bit MaskingConvert Binary to原创 2020-06-24 01:25:08 · 865 阅读 · 0 评论 -
Java ArrayList Class
In this tutorial, we will learn about the Java ArrayList class. We will learn about different ArrayList operations and methods with the help of examples.The ArrayList class is an implementation of the List interface that allows us to create resizable-arra原创 2020-06-23 01:33:13 · 796 阅读 · 0 评论 -
Introduction to Java 8 Lambda Expressions
Introduction to Java 8 Lambda ExpressionsLambda expressions were introduced in Java 8 and they became the talk of the town as soon as they arrived.Java has evolved a lot with time. It has incorporated new ideas and programming paradigms as and when neces原创 2020-06-22 18:17:50 · 241 阅读 · 0 评论 -
How to use Java functional Consumer interface example
Quite often a Java Stream or other component needs an object passed to it in order to perform some type of calculation or process, but when the process is complete, nothing gets returned from the method. This is where Java’s functional Consumer interface c原创 2020-06-22 17:51:50 · 179 阅读 · 0 评论 -
Java Lambda Expressions Basic
Syntax of Lambda ExpressionsA lambda expression consists of the following:A comma-separated list of formal parameters enclosed in parentheses. The CheckPerson.test method contains one parameter, p, which represents an instance of the Person class.Note原创 2020-06-17 01:21:27 · 196 阅读 · 0 评论 -
How to format Date and Time in Java
In this article, you’ll learn how to format Date and Time represented using Date, LocalDate, LocalDateTime, or ZonedDateTime to a readable String in Java.Format LocalDate using DateTimeFormatterpackage com.callicoder;import java.time.LocalDate;import.原创 2020-06-16 10:31:11 · 110 阅读 · 0 评论 -
Practice questions on Classes and objects Level Basic
Level 1Create a class named ‘Student’ with String variable ‘name’ and integer variable ‘roll_no’. Assign the value of roll_no as ‘2’ and that of name as “John” by creating an object of the class Student.package com.codesdope;public class Student {原创 2020-06-16 00:45:35 · 313 阅读 · 0 评论 -
How to get current Date and Time in Java
How to get current Date and Time in JavaIn this article, you’ll find several examples to get the current date, current time, current date & time, current date & time in a specific timezone in Java.Get current Date in Javapackage com.callicoder;原创 2020-06-15 13:58:13 · 173 阅读 · 0 评论 -
How to delete a directory recursively with all its subdirectories and files in Java
In this short article, you’ll learn how to delete a directory recursively along with all its subdirectories and files.There are two examples that demonstrate how to achieve this task. The idea behind both of the examples is to traverse the file tree, and.原创 2020-06-12 13:23:50 · 256 阅读 · 0 评论 -
How to Create a new file in java
How to Create a new file in javaThere are various ways in which you can create a new file in Java. In this article, I’ve outlined the two most recommended way of creating new files.Create New file using Java NIO (Recommended) - JDK 7+You can use [Files原创 2020-06-11 16:52:13 · 127 阅读 · 0 评论 -
Maven Java Example Application
In this application, we will create a simple adder that computes the sum of two integers. During this process, we will:Generate a Maven project using the Maven command-line toolConfigure the pom.xml fileCreate main and test source code filesExecute a原创 2020-06-09 18:04:07 · 187 阅读 · 0 评论 -
Classes and Objects in Java Part I
Classes and Objects are basic concepts of Object Oriented Programming which revolve around the real life entities.ClassA class is a user defined blueprint or prototype from which objects are created. It represents the set of properties or methods that a原创 2020-06-09 00:00:35 · 116 阅读 · 0 评论 -
Conditional Statement
Conditional Statement1. Write a program in Java to print the Floyd’s Triangle.package com.w3resource;import java.util.Scanner;public class FloydTriangle { public static void main(String[] args) { int i, j, n, p, q;原创 2020-06-07 22:48:51 · 542 阅读 · 0 评论 -
Recursion Fundamentals
1. Java Program to Reverse a Sentence Using Recursionlearn to reverse a given sentence using a recursive loop in Java.Example: Reverse a Sentence Using Recursionpackage com.programiz;public class ReverseSentence { public static void main(Stri原创 2020-06-07 13:15:35 · 204 阅读 · 0 评论 -
Java Array Exercises Practice Solution I
Java Array: Exercises Practice Solution1. Write a Java program to reverse an array of integer values.package com.w3resource;import java.util.Arrays;public class ReverseArray { public static void main(String[] args) { int[]原创 2020-06-06 23:59:28 · 159 阅读 · 0 评论 -
Maven Getting Started Guide I
Download and Installation instructions.SectionsWhat is Maven?How can Maven benefit my development process?How do I setup Maven?How do I make my first Maven project?How do I compile my application sources?How do I compile my test sources and run my原创 2020-06-05 22:53:54 · 166 阅读 · 0 评论 -
BubbleSort
排序算法之冒泡排序目录冒泡排序介绍O(n^2)的实现方法优化思路1. 冒泡排序介绍冒泡排序是一种比较简单的排序方法,以数组升序的情况为例,它的原理是从第一个元素开始,每个元素都与其相邻的元素做比较,如果前一个元素比后一个元素大,则交换两个元素的位置,每一轮排序都确定一个最大值。它是一种稳定的排序方法,因为两个元素相等时不会做交换,相对位置不会发生改变。2. O(n^2)的实现方法package com.zetcode;public class BubbleSort {原创 2020-06-05 00:54:05 · 118 阅读 · 0 评论 -
Practice questions on Array
Level I1. Take 10 integer inputs from user and store them in an array and print them on screen.package com.codesdope;import java.util.Scanner;public class StoreInputAndPrint { public static void main(String[] args) { Scanner s = new Sca原创 2020-06-03 15:27:14 · 272 阅读 · 0 评论 -
Array Basic
Java Program to Find Largest Element of an arrayIn this program, you’ll learn to find the largest element in an array using a for loop in Java.Example: Find largest element in an arraypackage com.programiz;public class Largest { public static voi原创 2020-06-02 23:52:56 · 302 阅读 · 0 评论 -
Data Types II
In this part of the Java tutorial, we continue covering data types of Java. We cover wrapper classes, boxing and unboxing, default values, conversions, and promotions.Java Wrapper ClassesWrapper classes are object representations of primitive data types.原创 2020-06-01 16:13:17 · 277 阅读 · 0 评论 -
Java Program to Calculate Standard Deviation
In this program, you’ll learn to calculate the standard deviation using a function in Java.This program calculates the standard deviation of a individual series using arrays. Visit this page to learn about Standard Deviation.To calculate the standard dev原创 2020-05-31 23:58:07 · 243 阅读 · 0 评论 -
MacBook Pro jdk Installation、Update、Delete
MacBook Pro jdk卸载步骤步骤一、输入以下命令sudo rm -rf /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin步骤二、上述命令执行后会提示输入超级管理员密码,完成后再次输入以下命令sudo rm -rf /Library/PreferencesPanes/JavaControlPanel.prefpane步骤三、查看当前版本ls /Library/Java/JavaVirtualMachines/步骤四、上述命令执原创 2020-05-31 00:51:37 · 236 阅读 · 0 评论 -
Java Code To Create Pyramid and Pattern
In this program, you’ll learn to create pyramid, half pyramid, inverted pyramid, Pascal’s triangle and Floyd’s triangle sing control statements in Java.Programs to print triangles using *, numbers and charactersExample 1: Program to print half pyramid u原创 2020-05-25 00:51:59 · 145 阅读 · 0 评论 -
Java language
JavaJava is a high-level, general-purpose, object-oriented programming language. The main design goals of the language were robustness, portability, high performance and security. Java is a multithreaded and distributed programming language. It can be use原创 2020-05-24 22:57:48 · 983 阅读 · 0 评论