Skip to content

Commit

Permalink
Make private main ctor. for CountOf and PropertiesOf
Browse files Browse the repository at this point in the history
  • Loading branch information
ixmanuel committed Jul 30, 2017
1 parent 341c351 commit e3d7317
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 13 deletions.
2 changes: 1 addition & 1 deletion src/main/java/org/cactoos/CountOf.java
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public CountOf(final Iterator<?> iterator) {
* Ctor.
* @param sclr The underlying scalar length
*/
public CountOf(final Scalar<?> sclr) {
private CountOf(final Scalar<?> sclr) {
this.scalar = new UncheckedScalar<>(sclr);
}

Expand Down
14 changes: 2 additions & 12 deletions src/main/java/org/cactoos/list/PropertiesOf.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,10 @@
import java.io.InputStream;
import java.util.Map;
import java.util.Properties;
import org.cactoos.Bytes;
import org.cactoos.Input;
import org.cactoos.Scalar;
import org.cactoos.Text;
import org.cactoos.func.IoCheckedScalar;
import org.cactoos.io.BytesOf;
import org.cactoos.io.InputOf;
import org.cactoos.text.TextOf;

Expand Down Expand Up @@ -67,15 +65,7 @@ public PropertiesOf(final String string) {
* @param text Text
*/
public PropertiesOf(final Text text) {
this(new BytesOf(text));
}

/**
* Ctor.
* @param bytes Bytes
*/
public PropertiesOf(final Bytes bytes) {
this(new InputOf(bytes));
this(new InputOf(text));
}

/**
Expand Down Expand Up @@ -134,7 +124,7 @@ public PropertiesOf(final Map<?, ?> map) {
* Ctor.
* @param sclr The underlying properties
*/
public PropertiesOf(final Scalar<Properties> sclr) {
private PropertiesOf(final Scalar<Properties> sclr) {
this.scalar = new IoCheckedScalar<>(sclr);
}

Expand Down

0 comments on commit e3d7317

Please sign in to comment.