simter-core

Simter Core

Лицензия

Лицензия

MIT
Группа

Группа

tech.simter
Идентификатор

Идентификатор

simter-core
Последняя версия

Последняя версия

1.1.0
Дата

Дата

Тип

Тип

jar
Описание

Описание

simter-core
Simter Core
Ссылка на сайт

Ссылка на сайт

https://github.com/simter/simter-core
Организация-разработчик

Организация-разработчик

simter
Система контроля версий

Система контроля версий

https://github.com/simter/simter-core.git

Скачать simter-core

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/tech.simter/simter-core/ -->
<dependency>
    <groupId>tech.simter</groupId>
    <artifactId>simter-core</artifactId>
    <version>1.1.0</version>
</dependency>
// https://jarcasting.com/artifacts/tech.simter/simter-core/
implementation 'tech.simter:simter-core:1.1.0'
// https://jarcasting.com/artifacts/tech.simter/simter-core/
implementation ("tech.simter:simter-core:1.1.0")
'tech.simter:simter-core:jar:1.1.0'
<dependency org="tech.simter" name="simter-core" rev="1.1.0">
  <artifact name="simter-core" type="jar" />
</dependency>
@Grapes(
@Grab(group='tech.simter', module='simter-core', version='1.1.0')
)
libraryDependencies += "tech.simter" % "simter-core" % "1.1.0"
[tech.simter/simter-core "1.1.0"]

Зависимости

test (1)

Идентификатор библиотеки Тип Версия
org.junit.jupiter : junit-jupiter jar

Модули Проекта

Данный проект не имеет модулей.

simter-core [中文]

Some base or common things. Includes:

  • Annotation (tech.simter.annotation)
    • The Format annotation class: Use to config the output format of the property value. Special for data/time property
    • The Comment annotation class: Use to define a description on the target package, class, field or method
  • Persistence (tech.simter.persistence)
    • The PersistenceEnum Enum: The persistence interface with persistence value.
    • The CommonState Enum implemented PersistenceEnum: Defined common state, such as Draft(1), Enabled(2), Disabled(4) and Deleted(8).
    • The Sex Enum implemented PersistenceEnum: Defined common state, such as Undefined(1), Male(2) and Female(4).
  • Common data class/interface (tech.simter.data)
    • The Page<T> interface: A page is a sublist of a list of objects.
    • The Id<T> class: A simple ID holder with a id property.
    • The Ts class: A simple timestamp holder with a ts property.
    • The Created<T> class extend Id<T>: The Created info object. It holds the identity and timestamp info. It has id and ts property.
    • The Option class: An option for simple text/value holder. It's similar to 'HTML DOM Option' object. It has text and value property.
    • The Node class: A tree-node data holder.
    • The ImportedResult class: A result holder for imported.

1. Installation

<dependency>
  <groupId>tech.simter</groupId>
  <artifactId>simter-core</artifactId>
  <version>1.0.0</version>
</dependency>

2. Requirement

  • Java 8+

3. Usage

3.1. Format

@Format("yyyy-MM-dd HH:mm")
private LocalDateTime createOn;

3.2. Comment

@Comment("The document's create-time")
private LocalDateTime createOn;

3.3 Page<T>

List<String> rows = Arrays.asList("a", "b");
Page<String> page = Page.build(1, 25, rows, 100L);
assertThat(page.getNumber(), is(1));
assertThat(page.getCapacity(), is(25));
assertThat(page.getRows(), is(rows));
assertThat(page.getTotalCount(), is(100L));

4. Build

mvn clean package

5. Deploy

First take a look at simter-parent deploy config.

5.1. Deploy to LAN Nexus Repository

mvn clean deploy -P lan

5.2. Deploy to Sonatype Repository

mvn clean deploy -P sonatype

After deployed, login into https://oss.sonatype.org. Through Staging Repositories, search this package, then close and release it. After couple hours, it will be synced to Maven Central Repository.

5.3. Deploy to Bintray Repository

mvn clean deploy -P bintray

Will deploy to https://api.bintray.com/maven/simter/maven/tech.simter:simter-core/;publish=1. So first create a package https://bintray.com/simter/maven/tech.simter:simter-core on Bintray. After deployed, check it from https://jcenter.bintray.com/tech/simter/simter-core.

tech.simter

Версии библиотеки

Версия
1.1.0
1.0.0
0.4.0
0.3.0