Skip to content

Commit

Permalink
Merge pull request #329 from Concordium/features-for-mobile
Browse files Browse the repository at this point in the history
Features for mobile
  • Loading branch information
shjortConcordium authored Mar 18, 2024
2 parents 17eab40 + c80a3a5 commit 60357e3
Show file tree
Hide file tree
Showing 31 changed files with 33 additions and 33 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Changelog

## Unreleased changes
## 7.1.0
- Removed unnecessary `amount` parameter from `InvokeInstanceRequest`.
- Added utility functions for converting between `CCDAmount` and `Energy`. Present in utility class `Converter`.
- Fixed a bug in `CustomEvent`. Removed unnecessary `tag` field.
Expand Down
2 changes: 1 addition & 1 deletion concordium-android-sdk/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>com.concordium.sdk</groupId>
<artifactId>concordium-sdk-base</artifactId>
<version>7.0.1-SNAPSHOT</version>
<version>7.1.0</version>
</parent>

<artifactId>concordium-android-sdk</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion concordium-sdk-examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<dependency>
<groupId>com.concordium.sdk</groupId>
<artifactId>concordium-sdk</artifactId>
<version>7.0.1-SNAPSHOT</version>
<version>7.1.0</version>
<scope>compile</scope>
</dependency>
<dependency>
Expand Down
2 changes: 1 addition & 1 deletion concordium-sdk/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>com.concordium.sdk</groupId>
<artifactId>concordium-sdk-base</artifactId>
<version>7.0.1-SNAPSHOT</version>
<version>7.1.0</version>
</parent>

<groupId>com.concordium.sdk</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import com.concordium.sdk.crypto.wallet.credential.CredentialDeploymentDetails;
import com.concordium.sdk.crypto.wallet.credential.CredentialDeploymentSerializationContext;
import com.concordium.sdk.crypto.wallet.web3Id.AcceptableRequest;
import com.concordium.sdk.crypto.wallet.web3Id.AttributeCheck;
import com.concordium.sdk.exceptions.JNIError;
import com.concordium.sdk.transactions.InitName;
import com.concordium.sdk.transactions.ReceiveName;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,13 @@
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;

import lombok.Builder;
import lombok.Getter;
import lombok.extern.jackson.Jacksonized;

@Builder
@Getter
@Jacksonized
public class AttributeList {

private Map<AttributeType, String> chosenAttributes;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,13 @@

import com.concordium.sdk.responses.accountinfo.credential.AttributeType;

import lombok.Builder;
import lombok.Getter;
import lombok.extern.jackson.Jacksonized;

@Builder
@Getter
@Jacksonized
public class IdentityObject {

private AttributeList attributeList;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.concordium.sdk.crypto.wallet.web3Id.Statement;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonSubTypes.Type;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

@Getter
@JsonTypeName("AttributeInSet")
public class MembershipStatement extends AtomicStatement {
public class MembershipStatement extends AtomicStatement implements SetStatement {
private String attributeTag;
private List<CredentialAttribute> set;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

@Getter
@JsonTypeName("AttributeNotInSet")
public class NonMembershipStatement extends AtomicStatement {
public class NonMembershipStatement extends AtomicStatement implements SetStatement {
private String attributeTag;
private List<CredentialAttribute> set;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import java.util.stream.Collectors;

import com.concordium.sdk.crypto.wallet.identityobject.IdentityObject;
import com.concordium.sdk.crypto.wallet.web3Id.Statement.did.RequestIdentifier;
import com.fasterxml.jackson.annotation.JsonProperty;

import lombok.Getter;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package com.concordium.sdk.crypto.wallet.web3Id.Statement;

import java.util.List;

import com.concordium.sdk.crypto.wallet.web3Id.CredentialAttribute;

public interface SetStatement {
public String getAttributeTag();
public List<CredentialAttribute> getSet();
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
package com.concordium.sdk.crypto.wallet.web3Id.Statement;

import org.apache.commons.codec.binary.Hex;

import com.concordium.sdk.crypto.ed25519.ED25519PublicKey;
import com.concordium.sdk.crypto.wallet.Network;
import com.concordium.sdk.crypto.wallet.web3Id.Statement.did.AccountRequestIdentifier;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
import java.util.stream.Collectors;
import com.concordium.sdk.crypto.wallet.web3Id.Statement.QualifiedRequestStatement;
import com.concordium.sdk.crypto.wallet.web3Id.Statement.UnqualifiedRequestStatement;
import com.concordium.sdk.serializing.JsonMapper;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.JsonMappingException;

import lombok.Builder;
import lombok.Getter;
import lombok.extern.jackson.Jacksonized;
Expand All @@ -30,4 +34,8 @@ public QualifiedRequest qualify(Qualifier qualifier) {
public static interface Qualifier {
QualifiedRequestStatement qualify(UnqualifiedRequestStatement statement);
}

public static UnqualifiedRequest fromJson(String raw) throws JsonMappingException, JsonProcessingException {
return JsonMapper.INSTANCE.readValue(raw, UnqualifiedRequest.class);
}
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.transactions.smartcontracts.WasmModule;
import com.concordium.sdk.types.UInt64;
import lombok.Builder;
import lombok.EqualsAndHashCode;
import lombok.Getter;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package com.concordium.sdk.transactions;


import com.concordium.sdk.types.AccountAddress;
import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
package com.concordium.sdk.transactions;


import com.concordium.sdk.types.AccountAddress;
import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
package com.concordium.sdk.transactions;


import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
import com.concordium.sdk.responses.ProtocolVersion;
import com.concordium.sdk.transactions.smartcontracts.SchemaParameter;
import com.concordium.sdk.types.UInt16;
import com.fasterxml.jackson.annotation.JsonCreator;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
import lombok.val;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.AccountAddress;
import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.AccountAddress;
import com.concordium.sdk.types.UInt16;
import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.AccountAddress;
import com.concordium.sdk.types.UInt16;
import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
package com.concordium.sdk.transactions;


import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.concordium.sdk.transactions;


import com.concordium.sdk.exceptions.TransactionCreationException;
import com.concordium.sdk.types.AccountAddress;
import com.concordium.sdk.types.Nonce;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.AccountAddress;
import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package com.concordium.sdk.transactions;

import com.concordium.sdk.types.UInt16;
import com.concordium.sdk.types.UInt64;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.ToString;
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<groupId>com.concordium.sdk</groupId>
<artifactId>concordium-sdk-base</artifactId>
<version>7.0.1-SNAPSHOT</version>
<version>7.1.0</version>
<packaging>pom</packaging>

<url>https://github.com/Concordium/concordium-java-sdk</url>
Expand Down

0 comments on commit 60357e3

Please sign in to comment.