[Git][java-team/access-modifier-checker][upstream] New upstream version 1.32

Emmanuel Bourg (@ebourg) gitlab at salsa.debian.org
Thu Sep 21 11:14:45 BST 2023



Emmanuel Bourg pushed to branch upstream at Debian Java Maintainers / access-modifier-checker


Commits:
96563d58 by Emmanuel Bourg at 2023-09-21T12:04:34+02:00
New upstream version 1.32
- - - - -


7 changed files:

- README.md
- access-modifier-annotation/pom.xml
- access-modifier-checker/pom.xml
- access-modifier-suppressions/pom.xml
- pom.xml
- − src/site/apt/index.apt
- − src/site/site.xml


Changes:

=====================================
README.md
=====================================
@@ -6,3 +6,54 @@ there's no runtime check either --- this is strictly a voluntary annotations.
 
 This mechanism is useful for actually making sure that deprecated features are not used
 (without actually removing such declarations, which would break binary compatibility.)
+
+## What is this?
+
+This library defines an annotation and extensible mechanism to let you define your own access modifiers.
+Those additional custom access modifiers can be enforced when you compile other source files that refer to them.
+
+For example, consider a deprecated feature in your library that you plan to remove in the near future.
+If you just put `@Deprecated`, code can be still written to use them quite casually (I still often use `Date.toGMTString()`, for example).
+But if you remove it, it'll break existing applications out there.
+Custom access modifier can fix this.
+With the following annotation on your method, you can flag an error whenever someone tries to call this method.
+
+```java
+public class Library {
+    @Deprecated @Restricted(DoNotUse.class)
+    public void foo() {
+        ...
+    }
+}
+```
+
+These checks are not enforced during the runtime, so in this way, you can keep the old application working, and at the same time prevent the new code from using this feature.
+(I should point out that technically speaking the enforcement is optional, even during the compile time -- after all, it's just a semantics imposed by a library external to Javac.)
+
+## Extensible Access Modifiers
+
+The library comes with a few built-in access modifiers, but your application can define your own by extending the `AccessRestriction` type.
+For example, maybe you want to allow read but prevent write to a field.
+Maybe you want to only allow certain methods to be called from within the constructor (or the other way around.)
+
+There's a lot of freedom.
+
+## Enforcing Access Modifiers
+
+Currently we provide a Maven mojo to enforce access modifiers.
+Use it like the following:
+
+```xml
+<plugin>
+  <groupId>org.kohsuke</groupId>
+  <artifactId>access-modifier-checker</artifactId>
+  <version>1.0</version>
+  <executions>
+    <execution>
+      <goals>
+        <goal>enforce</goal>
+      </goals>
+    </execution>
+  </executions>
+</plugin>
+```


=====================================
access-modifier-annotation/pom.xml
=====================================
@@ -4,7 +4,7 @@
   <parent>
     <groupId>org.kohsuke</groupId>
     <artifactId>access-modifier</artifactId>
-    <version>1.31</version>
+    <version>1.32</version>
   </parent>
   <artifactId>access-modifier-annotation</artifactId>
 


=====================================
access-modifier-checker/pom.xml
=====================================
@@ -4,7 +4,7 @@
   <parent>
     <groupId>org.kohsuke</groupId>
     <artifactId>access-modifier</artifactId>
-    <version>1.31</version>
+    <version>1.32</version>
   </parent>
   <artifactId>access-modifier-checker</artifactId>
   <packaging>maven-plugin</packaging>
@@ -47,13 +47,13 @@
       <!-- annotations are not used at runtime because @Retention(value=CLASS), they are needed only to build the plugin -->
       <groupId>org.apache.maven.plugin-tools</groupId>
       <artifactId>maven-plugin-annotations</artifactId>
-      <version>3.8.1</version>
+      <version>3.9.0</version>
       <optional>true</optional>
     </dependency>
     <dependency>
       <groupId>org.kohsuke.metainf-services</groupId>
       <artifactId>metainf-services</artifactId>
-      <version>1.9</version>
+      <version>1.11</version>
       <optional>true</optional>
     </dependency>
     <dependency>
@@ -102,7 +102,7 @@
         <plugins>
           <plugin>
             <artifactId>maven-invoker-plugin</artifactId>
-            <version>3.5.0</version>
+            <version>3.6.0</version>
             <executions>
               <execution>
                 <id>integration-test</id>


=====================================
access-modifier-suppressions/pom.xml
=====================================
@@ -4,7 +4,7 @@
   <parent>
     <groupId>org.kohsuke</groupId>
     <artifactId>access-modifier</artifactId>
-    <version>1.31</version>
+    <version>1.32</version>
   </parent>
   <artifactId>access-modifier-suppressions</artifactId>
 


=====================================
pom.xml
=====================================
@@ -4,13 +4,13 @@
   <parent>
     <groupId>org.jenkins-ci</groupId>
     <artifactId>jenkins</artifactId>
-    <version>1.95</version>
+    <version>1.101</version>
     <relativePath />
   </parent>
 
   <groupId>org.kohsuke</groupId>
   <artifactId>access-modifier</artifactId>
-  <version>1.31</version>
+  <version>1.32</version>
   <packaging>pom</packaging>
 
   <name>Custom access modifier for Java</name>
@@ -41,12 +41,12 @@
   <scm child.scm.connection.inherit.append.path="false" child.scm.developerConnection.inherit.append.path="false" child.scm.url.inherit.append.path="false">
     <connection>scm:git:https://github.com/${gitHubRepo}.git</connection>
     <developerConnection>scm:git:git at github.com:${gitHubRepo}.git</developerConnection>
-    <tag>access-modifier-1.31</tag>
+    <tag>access-modifier-1.32</tag>
     <url>https://github.com/${gitHubRepo}</url>
   </scm>
 
   <properties>
-    <revision>1.31</revision>
+    <revision>1.32</revision>
     <changelist>-SNAPSHOT</changelist>
     <gitHubRepo>jenkinsci/lib-access-modifier</gitHubRepo>
   </properties>
@@ -56,12 +56,12 @@
       <dependency>
         <groupId>org.codehaus.plexus</groupId>
         <artifactId>plexus-utils</artifactId>
-        <version>3.5.1</version>
+        <version>4.0.0</version>
       </dependency>
       <dependency>
         <groupId>org.ow2.asm</groupId>
         <artifactId>asm</artifactId>
-        <version>9.4</version>
+        <version>9.5</version>
       </dependency>
     </dependencies>
   </dependencyManagement>
@@ -99,7 +99,7 @@
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-plugin-plugin</artifactId>
-        <version>3.8.1</version>
+        <version>3.9.0</version>
         <executions>
           <!-- if you want to generate help goal -->
           <execution>


=====================================
src/site/apt/index.apt deleted
=====================================
@@ -1,45 +0,0 @@
-
-What is this?
-
-  This library defines an annotation and extensible mechanism to let you define your own access modifiers. Those additional custom access modifiers can be enforced when you compile other source files that refer them.
-  
-  For example, consider a deprecated feature in your library that you plan to remove in a near future. If you just put <<<@Deprecated>>>, code can be still written to use them quite casually (I still often use <<<Date.toGMTString()>>>, for example.) But if you remove it, it'll break existing applications out there. Custom access modifier can fix this. With the following annotation on your method, you can flag an error whenever someone tries to call this method.
-
------------------
-public class Library {
-    @Deprecated @Restricted(DoNotUse.class)
-    public void foo() {
-        ...
-    }
-}
------------------
-
-  These checks are not enforced during the runtime, so in this way, you can keep the old application working, and at the same time prevent the new code from using this feature. (I should point out that technically speaking the enforcement is optional, even during the compile time --- after all, it's just a semantics imposed by a library external to Javac.)
-
-
-Extensible Access Modifiers
-
-  The library comes with a few built-in access modifiers, but your application can define your own by extending the <<<AccessRestriction>>> type. For example, maybe you want to allow read but prevent write to a field. Maybe you want to only allow certain methods to be called from within the constructor (or the other way around.)
-
-  There's a lot of freedom.
-
-
-Enforcing Access Modifiers
-
-  Currently we provide a Maven mojo to enforce access modifiers. Use it like the following:
-
------------------
-      <plugin>
-        <groupId>org.kohsuke</groupId>
-        <artifactId>access-modifier-checker</artifactId>
-        <version>1.0</version>
-        <executions>
-          <execution>
-            <goals>
-              <goal>enforce</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
------------------
-


=====================================
src/site/site.xml deleted
=====================================
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<project name="Custom Access Modifier">
-  <bannerLeft>
-    <name>Custom Access Modifier</name>
-    <href>http://kohsuke.org/access-modifier</href>
-  </bannerLeft>
-  <skin>
-    <groupId>org.kohsuke</groupId>
-    <artifactId>maven-skin</artifactId>
-    <version>1.1</version>
-  </skin>
-  <!--<bannerRight>-->
-    <!--<src>http://maven.apache.org/images/maven-small.gif</src>-->
-  <!--</bannerRight>-->
-  <body>
-    <menu name="Custom Access Modifier">
-      <item name="Introduction" href="index.html"/>
-      <!--item name="User Guide" href="user-guide.html"/-->
-      <item name="Download" href="http://maven.dyndns.org/2/org/kohsuke/access-modifier/"/>
-    </menu>
-
-    <menu name="References">
-      <item name="Javadoc" href="apidocs/index.html"/>
-    </menu>
-
-    <menu ref="reports"/>
-  </body>
-</project>



View it on GitLab: https://salsa.debian.org/java-team/access-modifier-checker/-/commit/96563d5845b855b8802b7a23efc3c750fdf6a8d5

-- 
View it on GitLab: https://salsa.debian.org/java-team/access-modifier-checker/-/commit/96563d5845b855b8802b7a23efc3c750fdf6a8d5
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-java-commits/attachments/20230921/ffcc7a2b/attachment.htm>


More information about the pkg-java-commits mailing list