update format
Change-Id: I31dd0bab092139e98f922d12521d69d8955ec2ef
diff --git a/src/ca-state.hpp b/src/ca-state.hpp
index e6ad885..fefc0ff 100644
--- a/src/ca-state.hpp
+++ b/src/ca-state.hpp
@@ -44,7 +44,8 @@
/**
* @brief The state maintained by the Challenge modules
*/
-struct ChallengeState {
+struct ChallengeState
+{
ChallengeState(const std::string& challengeStatus, const time::system_clock::TimePoint& challengeTp,
size_t remainingTries, time::seconds remainingTime,
JsonSection&& challengeSecrets);
@@ -60,8 +61,8 @@
*
* ChallengeModule should take use of ChallengeState to keep state.
*/
-class CaState {
-
+class CaState
+{
public:
CaState();
CaState(const Name& caName, const std::string& requestId, RequestType requestType, Status status,
diff --git a/src/configuration.hpp b/src/configuration.hpp
index 9375758..eee8d35 100644
--- a/src/configuration.hpp
+++ b/src/configuration.hpp
@@ -112,7 +112,8 @@
* ]
* }
*/
-class CaConfig {
+class CaConfig
+{
public:
/**
* Load CA configuration from the file.
@@ -143,7 +144,8 @@
* For Client configuration format, please refer to:
* https://github.com/named-data/ndncert/wiki/Client-Configuration-Sample
*/
-class RequesterCaCache {
+class RequesterCaCache
+{
public:
/**
* @throw std::runtime_error when config file cannot be correctly parsed.
diff --git a/src/identity-challenge/challenge-module.hpp b/src/identity-challenge/challenge-module.hpp
index c12b03c..66f705e 100644
--- a/src/identity-challenge/challenge-module.hpp
+++ b/src/identity-challenge/challenge-module.hpp
@@ -26,7 +26,8 @@
namespace ndn {
namespace ndncert {
-class ChallengeModule : noncopyable {
+class ChallengeModule : noncopyable
+{
public:
explicit
ChallengeModule(const std::string& challengeType, size_t maxAttemptTimes, time::seconds secretLifetime);
diff --git a/src/name-assignments/assignment-funcs.hpp b/src/name-assignments/assignment-funcs.hpp
index 30408b5..42a34ed 100644
--- a/src/name-assignments/assignment-funcs.hpp
+++ b/src/name-assignments/assignment-funcs.hpp
@@ -26,7 +26,8 @@
namespace ndn {
namespace ndncert {
-class NameAssignmentFunc : noncopyable {
+class NameAssignmentFunc : noncopyable
+{
public:
explicit NameAssignmentFunc(const std::string& factoryType, const std::string& format = "");
diff --git a/src/name-assignments/assignment-hash.hpp b/src/name-assignments/assignment-hash.hpp
index b0cf417..a8ca6a6 100644
--- a/src/name-assignments/assignment-hash.hpp
+++ b/src/name-assignments/assignment-hash.hpp
@@ -29,7 +29,8 @@
/**
* assign names base on client probe parameter
*/
-class AssignmentHash: public NameAssignmentFunc {
+class AssignmentHash: public NameAssignmentFunc
+{
public:
AssignmentHash(const std::string& format = "");
diff --git a/src/name-assignments/assignment-random.hpp b/src/name-assignments/assignment-random.hpp
index a3e30dd..d145fc7 100644
--- a/src/name-assignments/assignment-random.hpp
+++ b/src/name-assignments/assignment-random.hpp
@@ -29,7 +29,8 @@
/**
* assign names base on client probe parameter
*/
-class AssignmentRandom: public NameAssignmentFunc {
+class AssignmentRandom: public NameAssignmentFunc
+{
public:
AssignmentRandom(const std::string& format = "");
@@ -37,9 +38,7 @@
assignName(const std::vector<std::tuple<std::string, std::string>>& params) override;
};
-}
-}
-
-
+} // namespace ndncert
+} // namespace ndn
#endif //NDNCERT_ASSIGNMENT_RANDOM_HPP
diff --git a/src/protocol-detail/challenge.hpp b/src/protocol-detail/challenge.hpp
index a506346..7d78009 100644
--- a/src/protocol-detail/challenge.hpp
+++ b/src/protocol-detail/challenge.hpp
@@ -27,7 +27,8 @@
namespace ndn {
namespace ndncert {
-class CHALLENGE {
+class CHALLENGE
+{
public:
static Block
encodeDataContent(const CaState& request);
diff --git a/src/protocol-detail/error.hpp b/src/protocol-detail/error.hpp
index bfda70c..ae3a027 100644
--- a/src/protocol-detail/error.hpp
+++ b/src/protocol-detail/error.hpp
@@ -26,7 +26,8 @@
namespace ndn {
namespace ndncert {
-class ErrorTLV {
+class ErrorTLV
+{
public:
/**
* Encode error information into a Data content TLV
diff --git a/src/protocol-detail/info.hpp b/src/protocol-detail/info.hpp
index 83214c9..67a38bf 100644
--- a/src/protocol-detail/info.hpp
+++ b/src/protocol-detail/info.hpp
@@ -26,7 +26,8 @@
namespace ndn {
namespace ndncert {
-class INFO {
+class INFO
+{
public:
/**
* Encode CA configuration and its certificate into a TLV block as INFO Data packet content.
diff --git a/src/protocol-detail/new-renew-revoke.hpp b/src/protocol-detail/new-renew-revoke.hpp
index ee393b1..53d60ac 100644
--- a/src/protocol-detail/new-renew-revoke.hpp
+++ b/src/protocol-detail/new-renew-revoke.hpp
@@ -26,7 +26,8 @@
namespace ndn {
namespace ndncert {
-class NEW_RENEW_REVOKE {
+class NEW_RENEW_REVOKE
+{
public:
static Block
encodeApplicationParameters(RequestType requestType, const std::string& ecdhPub, const security::Certificate& certRequest);
diff --git a/src/protocol-detail/probe.hpp b/src/protocol-detail/probe.hpp
index c973c07..52e6cb6 100644
--- a/src/protocol-detail/probe.hpp
+++ b/src/protocol-detail/probe.hpp
@@ -26,7 +26,8 @@
namespace ndn {
namespace ndncert {
-class PROBE {
+class PROBE
+{
public:
// For Client use
static Block