sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From o...@apache.org
Subject svn commit: r1710227 - /sling/trunk/bundles/extensions/settings/src/main/java/org/apache/sling/settings/impl/SlingIdUtil.java
Date Fri, 23 Oct 2015 14:46:12 GMT
Author: olli
Date: Fri Oct 23 14:46:12 2015
New Revision: 1710227

URL: http://svn.apache.org/viewvc?rev=1710227&view=rev
Log:
SLING-5190 factor out of SlingSettingsServiceImpl a Sling ID util

* make methods in SlingIdUtil public

Modified:
    sling/trunk/bundles/extensions/settings/src/main/java/org/apache/sling/settings/impl/SlingIdUtil.java

Modified: sling/trunk/bundles/extensions/settings/src/main/java/org/apache/sling/settings/impl/SlingIdUtil.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/settings/src/main/java/org/apache/sling/settings/impl/SlingIdUtil.java?rev=1710227&r1=1710226&r2=1710227&view=diff
==============================================================================
--- sling/trunk/bundles/extensions/settings/src/main/java/org/apache/sling/settings/impl/SlingIdUtil.java
(original)
+++ sling/trunk/bundles/extensions/settings/src/main/java/org/apache/sling/settings/impl/SlingIdUtil.java
Fri Oct 23 14:46:12 2015
@@ -28,14 +28,14 @@ import java.util.UUID;
 
 public class SlingIdUtil {
 
-    static String createSlingId() {
+    public static String createSlingId() {
         return UUID.randomUUID().toString();
     }
 
     /**
      * Read the id from a file.
      */
-    static String readSlingId(final File idFile, int maxLength) throws IOException {
+    public static String readSlingId(final File idFile, int maxLength) throws IOException
{
         if (idFile.exists() && idFile.length() >= maxLength) {
             DataInputStream dis = null;
             try {
@@ -60,7 +60,7 @@ public class SlingIdUtil {
     /**
      * Write the sling id file.
      */
-    static void writeSlingId(final File idFile, final String id) throws IOException {
+    public static void writeSlingId(final File idFile, final String id) throws IOException
{
         idFile.delete();
         idFile.getParentFile().mkdirs();
         DataOutputStream dos = null;



Mime
View raw message