Snippets

OICP 2.1 Authorize Start | Java

Updated by Julius Poessnecker

File (0) OICP Modified

  • Ignore whitespace
  • Hide word diff
-The service descrciption can be found in the OICP 2.1.
+The service description can be found in the OICP 2.1.
 
 Section:
 3.1.1 eRoamingAuthorizeStart
Updated by Julius Poessnecker

File (0) OICP Added

  • Ignore whitespace
  • Hide word diff
+The service descrciption can be found in the OICP 2.1.
+
+Section:
+3.1.1 eRoamingAuthorizeStart
+
+To download the latest OICP Version, please visit our website:
+https://www.hubject.com/downloads/
Updated by Gregor Schermuly

File (1) Authorize Start | Java.java Added

  • Ignore whitespace
  • Hide word diff
+/**
+ * Create a new OICP v2.0 AuthorizeStart request.
+ *
+ * @param EVSEOperatorId the unique identification of the EVSE operator for this request.
+ * @return a new AuthorizeStart request builder object.
+ */
+public AuthorizeStartRequest AuthorizeStart(final EVSEOperator_Id  EVSEOperatorId)
+{ ... }
+
+
+/**
+ * Create a new OICP v2.0 AuthorizeStart request.
+ *
+ * @param EVSEOperatorId the unique identification of the EVSE operator for this request.
+ * @param AuthToken the authentication token for this request.
+ * @return a new AuthorizeStart request builder object.
+ */
+public AuthorizeStartRequest AuthorizeStart(final EVSEOperator_Id  EVSEOperatorId,
+                                            final Auth_Token       AuthToken)
+{ ... }
+
+
+// AuthorizeStartRequest builder methods
+
+public AuthorizeStartRequest setEVSEId(EVSE_Id EVSEId)
+{ ... }
+
+
+public AuthorizeStartRequest setPartnerProductId(PartnerProduct_Id PartnerProductId)
+{ ... }
+
+
+public AuthorizeStartRequest setSessionId(ChargingSession_Id SessionId)
+{ ... }
+
+
+public AuthorizeStartRequest setPartnerSessionId(ChargingSession_Id PartnerSessionId)
+{ ... }
+
+
+public AuthorizeStartRequest setAuthToken(Auth_Token AuthToken)
+{ ... }
+
+
+public AuthorizeStartRequest setQRCodeIdentification(EVCO_Id  EVCOId,
+                                                     PIN      PIN)
+{ ... }
+
+
+public AuthorizeStartRequest setPlugAndChargeIdentification(EVCO_Id EVCOId)
+{ ... }
+
+
+public AuthorizeStartRequest setRemoteIdentification(EVCO_Id EVCOId)
+{ ... }

File (2) Example.java Added

  • Ignore whitespace
  • Hide word diff
+CompletableFuture req = new CPOClient("api.playground.hubject.com").
+
+    AuthorizeStart(EVSEOperator_Id.Parse("DE*GEF"),
+                   Auth_Token.     Parse("08152305")).
+
+    Run(result -> {
+
+        if (result.getAuthorizationStatus() == AuthorizationStatus.Authorized)
+            System.out.println("Authorized!");
+
+        else {
+            System.out.println(result.getStatusCode().getCode());
+            System.out.println(result.getStatusCode().getDescription());
+            System.out.println(result.getStatusCode().getAdditionalInfo());
+        }
+
+    });
+
+// Wait for the future to complete...
+req.get();

File Authorize Start | Java.java Deleted

  • Ignore whitespace
  • Hide word diff
-/**
- * Create a new OICP v2.0 AuthorizeStart request.
- *
- * @param EVSEOperatorId the unique identification of the EVSE operator for this request.
- * @return a new AuthorizeStart request builder object.
- */
-public AuthorizeStartRequest AuthorizeStart(final EVSEOperator_Id  EVSEOperatorId)
-{ ... }
-
-
-/**
- * Create a new OICP v2.0 AuthorizeStart request.
- *
- * @param EVSEOperatorId the unique identification of the EVSE operator for this request.
- * @param AuthToken the authentication token for this request.
- * @return a new AuthorizeStart request builder object.
- */
-public AuthorizeStartRequest AuthorizeStart(final EVSEOperator_Id  EVSEOperatorId,
-                                            final Auth_Token       AuthToken)
-{ ... }
-
-
-// AuthorizeStartRequest builder methods
-
-public AuthorizeStartRequest setEVSEId(EVSE_Id EVSEId)
-{ ... }
-
-
-public AuthorizeStartRequest setPartnerProductId(PartnerProduct_Id PartnerProductId)
-{ ... }
-
-
-public AuthorizeStartRequest setSessionId(ChargingSession_Id SessionId)
-{ ... }
-
-
-public AuthorizeStartRequest setPartnerSessionId(ChargingSession_Id PartnerSessionId)
-{ ... }
-
-
-public AuthorizeStartRequest setAuthToken(Auth_Token AuthToken)
-{ ... }
-
-
-public AuthorizeStartRequest setQRCodeIdentification(EVCO_Id  EVCOId,
-                                                     PIN      PIN)
-{ ... }
-
-
-public AuthorizeStartRequest setPlugAndChargeIdentification(EVCO_Id EVCOId)
-{ ... }
-
-
-public AuthorizeStartRequest setRemoteIdentification(EVCO_Id EVCOId)
-{ ... }

File Example.java Deleted

  • Ignore whitespace
  • Hide word diff
-CompletableFuture req = new CPOClient("api.playground.hubject.com").
-
-    AuthorizeStart(EVSEOperator_Id.Parse("DE*GEF"),
-                   Auth_Token.     Parse("08152305")).
-
-    Run(result -> {
-
-        if (result.getAuthorizationStatus() == AuthorizationStatus.Authorized)
-            System.out.println("Authorized!");
-
-        else {
-            System.out.println(result.getStatusCode().getCode());
-            System.out.println(result.getStatusCode().getDescription());
-            System.out.println(result.getStatusCode().getAdditionalInfo());
-        }
-
-    });
-
-// Wait for the future to complete...
-req.get();
Created by Gregor Schermuly

File Authorize Start | Java.java Added

  • Ignore whitespace
  • Hide word diff
+/**
+ * Create a new OICP v2.0 AuthorizeStart request.
+ *
+ * @param EVSEOperatorId the unique identification of the EVSE operator for this request.
+ * @return a new AuthorizeStart request builder object.
+ */
+public AuthorizeStartRequest AuthorizeStart(final EVSEOperator_Id  EVSEOperatorId)
+{ ... }
+
+
+/**
+ * Create a new OICP v2.0 AuthorizeStart request.
+ *
+ * @param EVSEOperatorId the unique identification of the EVSE operator for this request.
+ * @param AuthToken the authentication token for this request.
+ * @return a new AuthorizeStart request builder object.
+ */
+public AuthorizeStartRequest AuthorizeStart(final EVSEOperator_Id  EVSEOperatorId,
+                                            final Auth_Token       AuthToken)
+{ ... }
+
+
+// AuthorizeStartRequest builder methods
+
+public AuthorizeStartRequest setEVSEId(EVSE_Id EVSEId)
+{ ... }
+
+
+public AuthorizeStartRequest setPartnerProductId(PartnerProduct_Id PartnerProductId)
+{ ... }
+
+
+public AuthorizeStartRequest setSessionId(ChargingSession_Id SessionId)
+{ ... }
+
+
+public AuthorizeStartRequest setPartnerSessionId(ChargingSession_Id PartnerSessionId)
+{ ... }
+
+
+public AuthorizeStartRequest setAuthToken(Auth_Token AuthToken)
+{ ... }
+
+
+public AuthorizeStartRequest setQRCodeIdentification(EVCO_Id  EVCOId,
+                                                     PIN      PIN)
+{ ... }
+
+
+public AuthorizeStartRequest setPlugAndChargeIdentification(EVCO_Id EVCOId)
+{ ... }
+
+
+public AuthorizeStartRequest setRemoteIdentification(EVCO_Id EVCOId)
+{ ... }

File Example.java Added

  • Ignore whitespace
  • Hide word diff
+CompletableFuture req = new CPOClient("api.playground.hubject.com").
+
+    AuthorizeStart(EVSEOperator_Id.Parse("DE*GEF"),
+                   Auth_Token.     Parse("08152305")).
+
+    Run(result -> {
+
+        if (result.getAuthorizationStatus() == AuthorizationStatus.Authorized)
+            System.out.println("Authorized!");
+
+        else {
+            System.out.println(result.getStatusCode().getCode());
+            System.out.println(result.getStatusCode().getDescription());
+            System.out.println(result.getStatusCode().getAdditionalInfo());
+        }
+
+    });
+
+// Wait for the future to complete...
+req.get();
HTTPS SSH

You can clone a snippet to your computer for local editing. Learn more.