GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - package-url/packageurl-java: Java/JVM implementation of the package url spec

BranchesTags
Open more actions menu

Latest commit

 

History

310 Commits
310 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
.mvn
.mvn
 
 
src
src
 
 
.editorconfig
.editorconfig
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
.java-version
.java-version
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
bnd.bnd
bnd.bnd
 
 
pom.xml
pom.xml
 
 
release.sh
release.sh
 
 

Repository files navigation

Build Status Maven Central License

Package URL (purl) for Java

This project implements a purl parser and class for Java.

Requirements

  • The library has a runtime requirement of JRE 8 or newer.
  • To build the library from source, you need JDK 17 or newer.

Compiling

mvn clean install

Maven Usage

Package URL is available on the Maven Central Repository. These can be used without having to compile the project yourself.

<dependencies>
    <dependency>
        <groupId>com.github.package-url</groupId>
        <artifactId>packageurl-java</artifactId>
        <version>1.5.0</version>
    </dependency>
</dependencies>

Usage

Creates a new PackageURL object from a purl string:

PackageURL purl = new PackageURL(purlString);

Creates a new PackageURL object from parameters:

PackageURL purl = new PackageURL(type, namespace, name, version, qualifiers, subpath);

Creates a new PackageURL object using the builder pattern:

PackageURL purl = PackageURLBuilder.aPackageURL()
    .withType("type")
    .withNamespace("namespace")
    .withName("name")
    .withVersion("version")
    .withQualifier("key","value")
    .withSubpath("subpath")
    .build();

Validates a String field in a POJO (Bean Validation):

@PackageURL
private String purl;

License

Permission to modify and redistribute is granted under the terms of the MIT License

About

Java/JVM implementation of the package url spec

Topics

javajvm-languageslibrarypackage-urlpurl

Resources

Readme
MIT license
Activity
Custom properties

Stars

49 stars

Watchers

6 watching

Forks

26 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.