Skip to content

Commit

Permalink
Add private constructor to ImageUtils and comment to everywhere else (#…
Browse files Browse the repository at this point in the history
…71)

* Add private constructor to ImageUtils

* add comment about the private constructor everywhere

* comment
  • Loading branch information
im-konge authored May 14, 2024
1 parent d359c3e commit b26d8f0
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public class ExecBuilder {
/**
* Constructor
*/
public ExecBuilder() { }
public ExecBuilder() {}

/**
* Sets the command to execute.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ public interface ResourceType<T extends HasMetadata> {
*/
NonNamespaceOperation<?, ?, ?> getClient();


/**
* Kind of api resource
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@
public class ImageUtils {
private static final Logger LOGGER = LogManager.getLogger(ImageUtils.class);

private ImageUtils() {
// Private constructor to prevent instantiation
}

private static final Pattern IMAGE_PATTERN_FULL_PATH =
Pattern.compile("^(?<registry>[^/]*)/(?<org>[^/]*)/(?<image>[^:]*):(?<tag>.*)$");
private static final Pattern IMAGE_PATTERN = Pattern.compile("^(?<org>[^/]*)/(?<image>[^:]*):(?<tag>.*)$");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ public final class KubeUtils {
private static final Logger LOGGER = LogManager.getLogger(KubeUtils.class);

private KubeUtils() {
// Private constructor to prevent instantiation
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public final class TestFrameUtils {
public static final TimeUnit DEFAULT_TIMEOUT_UNIT = TimeUnit.SECONDS;

private TestFrameUtils() {
// Private constructor to prevent instantiation
}

/**
Expand Down

0 comments on commit b26d8f0

Please sign in to comment.