chetanmeh commented on a change in pull request #4559: Allow parameters to be 
designated as init time properties
URL: https://github.com/apache/openwhisk/pull/4559#discussion_r315522057
 
 

 ##########
 File path: 
common/scala/src/main/scala/org/apache/openwhisk/core/entity/Parameter.scala
 ##########
 @@ -144,19 +151,19 @@ protected[entity] class ParameterName protected[entity] 
(val name: String) exten
  * be undefined, such as when an action is created but the parameter value is 
not bound yet.
  * In general, this is an opaque value.
  *
- * It is a value type (hence == is .equals, immutable and cannot be assigned 
null).
  * The constructor is private so that argument requirements are checked and 
normalized
  * before creating a new instance.
  *
- * @param value the value of the parameter, may be null
+ * @param v the value of the parameter, may be null
+ * @param init if true, this parameter value is only offered to the action 
during initialization
  */
-protected[entity] class ParameterValue protected[entity] (private val v: 
JsValue) extends AnyVal {
+protected[entity] case class ParameterValue protected[entity] (private val v: 
JsValue, val init: Boolean) {
 
   /** @return JsValue if defined else JsNull. */
-  protected[entity] def value = Option(v) getOrElse JsNull
+  protected[entity] val value = Option(v) getOrElse JsNull
 
 Review comment:
   Just curious - Any reason to make them `val` instead of `def` as they would 
then consume small memory

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to