Skip to content

Commit

Permalink
use string enums
Browse files Browse the repository at this point in the history
  • Loading branch information
chaitanyapotti committed Oct 20, 2020
1 parent 32b0c6e commit e5c50ae
Show file tree
Hide file tree
Showing 5 changed files with 57 additions and 17 deletions.
2 changes: 2 additions & 0 deletions .idea/dictionaries/chai.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion torusdirect/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ android {
minSdkVersion 26
targetSdkVersion 30
versionCode 1
versionName "1.0.6"
versionName "1.0.7"

testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
consumerProguardFiles 'consumer-rules.pro'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
package org.torusresearch.torusdirect.types;

import org.jetbrains.annotations.NotNull;

public enum AggregateVerifierType {
SINGLE_VERIFIER_ID
SINGLE_VERIFIER_ID("single_verifier_id");

private String verifierType;

AggregateVerifierType(String verifierType) {
this.verifierType = verifierType;
}

@NotNull
public String toString() {
return verifierType;
}
}
Original file line number Diff line number Diff line change
@@ -1,17 +1,29 @@
package org.torusresearch.torusdirect.types;

import org.jetbrains.annotations.NotNull;

public enum LoginType {
GOOGLE,
FACEBOOK,
REDDIT,
DISCORD,
TWITCH,
APPLE,
GITHUB,
LINKEDIN,
TWITTER,
WEIBO,
LINE,
EMAIL_PASSWORD,
JWT
GOOGLE("google"),
FACEBOOK("facebook"),
REDDIT("reddit"),
DISCORD("discord"),
TWITCH("twitch"),
APPLE("apple"),
GITHUB("github"),
LINKEDIN("linkedin"),
TWITTER("twitter"),
WEIBO("weibo"),
LINE("line"),
EMAIL_PASSWORD("email_password"),
JWT("jwt");
private String loginType;

LoginType(String loginType) {
this.loginType = loginType;
}

@NotNull
public String toString() {
return loginType;
}
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
package org.torusresearch.torusdirect.types;

import org.jetbrains.annotations.NotNull;

public enum TorusNetwork {
MAINNET,
TESTNET
MAINNET("mainnet"),
TESTNET("testnet");

private String network;

TorusNetwork(String network) {
this.network = network;
}

@NotNull
public String toString() {
return network;
}
}

0 comments on commit e5c50ae

Please sign in to comment.