Skip to content

Commit

Permalink
Merge branch '__rultor'
Browse files Browse the repository at this point in the history
  • Loading branch information
rultor committed Jan 18, 2019
2 parents ded870e + ffdb262 commit 0a88360
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,15 @@
/**
* Decodes the origin text using the Base64 encoding scheme.
* @since 0.20.2
* @todo #980:30min Define new name for Base64Text and TextBase64 in order to
* avoid compound names. These classes are using for decode/encode text using
* the radix-64 representation.
*/
public final class Base64Text extends TextEnvelope {
public final class Base64Decoded extends TextEnvelope {

/**
* Ctor.
*
* @param input The String
*/
public Base64Text(final String input) {
public Base64Decoded(final String input) {
this(new TextOf(input));
}

Expand All @@ -51,7 +48,7 @@ public Base64Text(final String input) {
*
* @param origin Origin text
*/
public Base64Text(final Text origin) {
public Base64Decoded(final Text origin) {
super(new TextOf(
new Base64Bytes(
new BytesOf(origin)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@
*
* @since 0.20.2
*/
public final class TextBase64 extends TextEnvelope {
public final class Base64Encoded extends TextEnvelope {

/**
* Ctor.
*
* @param input The String
*/
public TextBase64(final String input) {
public Base64Encoded(final String input) {
this(new TextOf(input));
}

Expand All @@ -50,7 +50,7 @@ public TextBase64(final String input) {
*
* @param origin Origin text
*/
public TextBase64(final Text origin) {
public Base64Encoded(final Text origin) {
super((Scalar<String>) () -> new TextOf(
new BytesBase64(
new BytesOf(origin)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@
import org.llorllale.cactoos.matchers.TextHasString;

/**
* Test Case for {@link org.cactoos.text.Base64Text}.
* Test Case for {@link Base64Decoded}.
*
* @since 0.20.2
*/
public final class Base64TextTest {
public final class Base64DecodedTest {

/**
* Check text decodes using the Base64 encoding scheme.
Expand All @@ -44,7 +44,7 @@ public final class Base64TextTest {
public void checkDecode() throws IOException {
MatcherAssert.assertThat(
"Can't decodes text using the Base64 encoding scheme",
new Base64Text(
new Base64Decoded(
"SGVsbG8h"
),
new TextHasString(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@
import org.llorllale.cactoos.matchers.TextHasString;

/**
* Test case for {@link org.cactoos.text.TextBase64}.
* Test case for {@link Base64Encoded}.
* @since 0.20.2
*/
public final class TextBase64Test {
public final class Base64EncodedTest {

/**
* Check text encodes using the Base64 encoding scheme.
Expand All @@ -43,7 +43,7 @@ public final class TextBase64Test {
public void checkEncode() throws IOException {
MatcherAssert.assertThat(
"Can't encodes text using the Base64 encoding scheme",
new TextBase64(
new Base64Encoded(
"Hello!"
),
new TextHasString(
Expand Down

1 comment on commit 0a88360

@0pdd
Copy link
Collaborator

@0pdd 0pdd commented on 0a88360 Jan 18, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Puzzle 980-4cee6100 disappeared from src/main/java/org/cactoos/text/Base64Text.java, that's why I closed #1004. Please, remember that the puzzle was not necessarily removed in this particular commit. Maybe it happened earlier, but we discovered this fact only now.

Please sign in to comment.