This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


The following commit(s) were added to refs/heads/master by this push:
     new 28502ec7e7 ISIS-3202: update site index
28502ec7e7 is described below

commit 28502ec7e767ecf79eb2a612d28a4d05f6e4b1e8
Author: Andi Huber <ahu...@apache.org>
AuthorDate: Sun Sep 4 22:14:37 2022 +0200

    ISIS-3202: update site index
---
 .../pages/index/services/bookmark/Bookmark.adoc    | 16 ++++-
 .../index/services/bookmark/BookmarkHolder.adoc    |  8 +--
 .../index/services/bookmark/IdStringifier.adoc     | 11 +++
 .../index/services/repository/EntityState.adoc     | 80 +++++++++++++---------
 .../modules/applib/pages/index/value/Clob.adoc     |  1 +
 .../index/metamodel/object/ManagedObject.adoc      | 60 ++++------------
 .../publish/LifecycleCallbackNotifier.adoc         |  8 ++-
 .../publish/ObjectLifecyclePublisherDefault.adoc   |  2 +-
 core/adoc/modules/_overview/pages/about.adoc       |  2 +-
 9 files changed, 101 insertions(+), 87 deletions(-)

diff --git 
a/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/Bookmark.adoc
 
b/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/Bookmark.adoc
index c62b5f3023..58bc87615d 100644
--- 
a/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/Bookmark.adoc
+++ 
b/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/Bookmark.adoc
@@ -11,13 +11,13 @@ String representation of any persistable or re-creatable 
object managed by the f
 class Bookmark {
   Bookmark empty(LogicalType logicalType)
   Bookmark emptyForLogicalTypeName(String logicalTypeName)
-  Bookmark forLogicalTypeNameAndIdentifier(String logicalTypeName, String 
identifier)
-  Bookmark forLogicalTypeAndIdentifier(LogicalType logicalType, String 
identifier)
+  Bookmark forLogicalTypeNameAndIdentifier(String logicalTypeName, String 
urlSafeIdentifier)
+  Bookmark forLogicalTypeAndIdentifier(LogicalType logicalType, String 
urlSafeIdentifier)
   Bookmark forOidDto(OidDto oidDto)
   Bookmark withHintId(String hintId)
   Optional<Bookmark> parse(String str)     // <.>
   Bookmark parseElseFail(String input)
-  Optional<Bookmark> parseUrlEncoded(String urlEncodedStr)
+  Optional<Bookmark> parseUrlEncoded(String urlEncodedStr)     // <.>
   OidDto toOidDto()
   String stringify()
   boolean equals(Object other)
@@ -34,6 +34,11 @@ class Bookmark {
 --
 Round-trip with _#stringify()_ representation.
 --
+<.> xref:#parseUrlEncoded_String[parseUrlEncoded(String)]
++
+--
+there is only one use-case, that is, if a bookmark itself needs to be encoded 
(eg. page params)
+--
 <.> xref:#stringifyHonoringHintIfAny_[stringifyHonoringHintIfAny()]
 +
 --
@@ -52,6 +57,11 @@ Whether represents _null_ .
 
 Round-trip with _#stringify()_ representation.
 
+[#parseUrlEncoded_String]
+=== parseUrlEncoded(String)
+
+there is only one use-case, that is, if a bookmark itself needs to be encoded 
(eg. page params)
+
 [#stringifyHonoringHintIfAny_]
 === stringifyHonoringHintIfAny()
 
diff --git 
a/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/BookmarkHolder.adoc
 
b/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/BookmarkHolder.adoc
index f82ce3c07d..b95d5b706d 100644
--- 
a/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/BookmarkHolder.adoc
+++ 
b/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/BookmarkHolder.adoc
@@ -11,11 +11,11 @@ The framework provides mixins that surface the bookmarked 
domain object as eithe
 .BookmarkHolder.java
 ----
 interface BookmarkHolder {
-  Bookmark bookmark()     // <.>
+  Bookmark getBookmark()     // <.>
 }
 ----
 
-<.> xref:#bookmark_[bookmark()]
+<.> xref:#getBookmark_[getBookmark()]
 +
 --
 A reference to an arbitrary domain object, as a 
xref:refguide:applib:index/services/bookmark/Bookmark.adoc[Bookmark] .
@@ -23,7 +23,7 @@ A reference to an arbitrary domain object, as a 
xref:refguide:applib:index/servi
 
 == Members
 
-[#bookmark_]
-=== bookmark()
+[#getBookmark_]
+=== getBookmark()
 
 A reference to an arbitrary domain object, as a 
xref:refguide:applib:index/services/bookmark/Bookmark.adoc[Bookmark] .
diff --git 
a/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/IdStringifier.adoc
 
b/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/IdStringifier.adoc
index c6a6e10934..f0ad68e1f4 100644
--- 
a/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/IdStringifier.adoc
+++ 
b/antora/components/refguide-index/modules/applib/pages/index/services/bookmark/IdStringifier.adoc
@@ -17,6 +17,7 @@ interface IdStringifier<T> {
   Class<T> getCorrespondingClass()
   String enstring(T value)     // <.>
   T destring(Class<?> targetEntityClass, String stringified)     // <.>
+  boolean isValid(T value)     // <.>
 }
 ----
 
@@ -30,6 +31,11 @@ Convert the value (which will be of the same type as 
returned by _#getCorrespond
 --
 Convert a string representation of the identifier (as returned by 
_#enstring(Object)_ ) into an object that can be used to retrieve.
 --
+<.> xref:#isValid_T[isValid(T)]
++
+--
+Whether the non-null primary key object is valid, that is, in the case of a 
composite, whether it is fully populated.
+--
 
 == Members
 
@@ -42,3 +48,8 @@ Convert the value (which will be of the same type as returned 
by _#getCorrespond
 === destring(Class, String)
 
 Convert a string representation of the identifier (as returned by 
_#enstring(Object)_ ) into an object that can be used to retrieve.
+
+[#isValid_T]
+=== isValid(T)
+
+Whether the non-null primary key object is valid, that is, in the case of a 
composite, whether it is fully populated.
diff --git 
a/antora/components/refguide-index/modules/applib/pages/index/services/repository/EntityState.adoc
 
b/antora/components/refguide-index/modules/applib/pages/index/services/repository/EntityState.adoc
index 87eb830ca3..2ec790cca0 100644
--- 
a/antora/components/refguide-index/modules/applib/pages/index/services/repository/EntityState.adoc
+++ 
b/antora/components/refguide-index/modules/applib/pages/index/services/repository/EntityState.adoc
@@ -11,17 +11,19 @@ Enumerates the state of an entity.
 enum EntityState {
   NOT_PERSISTABLE     // <.>
   PERSISTABLE_ATTACHED     // <.>
-  PERSISTABLE_NEW     // <.>
   PERSISTABLE_DETACHED     // <.>
   PERSISTABLE_REMOVED     // <.>
+  PERSISTABLE_ATTACHED_NO_OID     // <.>
+  PERSISTABLE_DETACHED_WITH_OID     // <.>
   boolean isPersistable()     // <.>
   boolean isAttached()     // <.>
-  boolean isNew()     // <.>
   boolean isDetached()     // <.>
   boolean isRemoved()     // <.>
-  boolean isDetachedOrRemoved()     // <.>
+  boolean isDetachedCannotReattach()
   boolean isAttachedOrRemoved()     // <.>
-  boolean isAttachedOrNew()     // <.>
+  boolean isSpecicalJdoAttachedNoOid()     // <.>
+  boolean isSpecicalJpaDetachedWithOid()     // <.>
+  boolean hasOid()
 }
 ----
 
@@ -35,11 +37,6 @@ Object with this state is not an entity (for example it 
might be a view model, v
 --
 Object with this state is an entity that is attached to a persistence session, 
in other words changes to the entity will be flushed back to the database.
 --
-<.> xref:#PERSISTABLE_NEW[PERSISTABLE_NEW]
-+
---
-DN/JDO specific on pre-store. Is attached, has no OID yet.
---
 <.> xref:#PERSISTABLE_DETACHED[PERSISTABLE_DETACHED]
 +
 --
@@ -50,6 +47,16 @@ Object with this state is an entity but that is detached 
from a persistence sess
 --
 Object with this state is an entity that has been removed from the database. 
Objects in this state may no longer be interacted with.
 --
+<.> xref:#PERSISTABLE_ATTACHED_NO_OID[PERSISTABLE_ATTACHED_NO_OID]
++
+--
+DN/JDO specific on pre-store. Is attached, has no OID yet.
+--
+<.> xref:#PERSISTABLE_DETACHED_WITH_OID[PERSISTABLE_DETACHED_WITH_OID]
++
+--
+JPA specific. Is detached, but has an OID.
+--
 <.> xref:#isPersistable_[isPersistable()]
 +
 --
@@ -60,11 +67,6 @@ Object is an entity so is _potentially_ persistable ot the 
database.
 --
 Object with this state is an entity that is attached to a persistence session, 
in other words changes to the entity will be flushed back to the database.
 --
-<.> xref:#isNew_[isNew()]
-+
---
-DN/JDO specific on pre-store. Is attached, has no OID yet.
---
 <.> xref:#isDetached_[isDetached()]
 +
 --
@@ -75,9 +77,18 @@ Object with this state is an entity but that is detached 
from a persistence sess
 --
 Object with this state is an entity that has been removed from the database. 
Objects in this state may no longer be interacted with.
 --
-<.> xref:#isDetachedOrRemoved_[isDetachedOrRemoved()]
 <.> xref:#isAttachedOrRemoved_[isAttachedOrRemoved()]
-<.> xref:#isAttachedOrNew_[isAttachedOrNew()]
++
+--
+[WARNING]
+====
+[red]#_deprecated:_#
+
+not supported by JPA
+====
+--
+<.> xref:#isSpecicalJdoAttachedNoOid_[isSpecicalJdoAttachedNoOid()]
+<.> xref:#isSpecicalJpaDetachedWithOid_[isSpecicalJpaDetachedWithOid()]
 
 == Members
 
@@ -91,11 +102,6 @@ Object with this state is not an entity (for example it 
might be a view model, v
 
 Object with this state is an entity that is attached to a persistence session, 
in other words changes to the entity will be flushed back to the database.
 
-[#PERSISTABLE_NEW]
-=== PERSISTABLE_NEW
-
-DN/JDO specific on pre-store. Is attached, has no OID yet.
-
 [#PERSISTABLE_DETACHED]
 === PERSISTABLE_DETACHED
 
@@ -106,6 +112,16 @@ Object with this state is an entity but that is detached 
from a persistence sess
 
 Object with this state is an entity that has been removed from the database. 
Objects in this state may no longer be interacted with.
 
+[#PERSISTABLE_ATTACHED_NO_OID]
+=== PERSISTABLE_ATTACHED_NO_OID
+
+DN/JDO specific on pre-store. Is attached, has no OID yet.
+
+[#PERSISTABLE_DETACHED_WITH_OID]
+=== PERSISTABLE_DETACHED_WITH_OID
+
+JPA specific. Is detached, but has an OID.
+
 [#isPersistable_]
 === isPersistable()
 
@@ -116,11 +132,6 @@ Object is an entity so is _potentially_ persistable ot the 
database.
 
 Object with this state is an entity that is attached to a persistence session, 
in other words changes to the entity will be flushed back to the database.
 
-[#isNew_]
-=== isNew()
-
-DN/JDO specific on pre-store. Is attached, has no OID yet.
-
 [#isDetached_]
 === isDetached()
 
@@ -133,11 +144,18 @@ Object with this state is an entity that has been removed 
from the database. Obj
 
 Only supported by JDO. Will always return false with JPA.
 
-[#isDetachedOrRemoved_]
-=== isDetachedOrRemoved()
-
 [#isAttachedOrRemoved_]
 === isAttachedOrRemoved()
 
-[#isAttachedOrNew_]
-=== isAttachedOrNew()
+[WARNING]
+====
+[red]#_deprecated:_#
+
+not supported by JPA
+====
+
+[#isSpecicalJdoAttachedNoOid_]
+=== isSpecicalJdoAttachedNoOid()
+
+[#isSpecicalJpaDetachedWithOid_]
+=== isSpecicalJpaDetachedWithOid()
diff --git 
a/antora/components/refguide-index/modules/applib/pages/index/value/Clob.adoc 
b/antora/components/refguide-index/modules/applib/pages/index/value/Clob.adoc
index feaa64642b..c07ca86988 100644
--- 
a/antora/components/refguide-index/modules/applib/pages/index/value/Clob.adoc
+++ 
b/antora/components/refguide-index/modules/applib/pages/index/value/Clob.adoc
@@ -27,6 +27,7 @@ class Clob {
   CharSequence getChars()
   Blob toBlob(Charset charset)
   void writeCharsTo(Writer wr)
+  String asString()
   boolean equals(Object o)
   int hashCode()
   String toString()
diff --git 
a/antora/components/refguide-index/modules/core/pages/index/metamodel/object/ManagedObject.adoc
 
b/antora/components/refguide-index/modules/core/pages/index/metamodel/object/ManagedObject.adoc
index 24a4dd830a..6bbb081f70 100644
--- 
a/antora/components/refguide-index/modules/core/pages/index/metamodel/object/ManagedObject.adoc
+++ 
b/antora/components/refguide-index/modules/core/pages/index/metamodel/object/ManagedObject.adoc
@@ -14,30 +14,28 @@ interface ManagedObject {
   ObjectSpecification getSpecification()     // <.>
   Object getPojo()     // <.>
   EntityState getEntityState()
-  void refreshViewmodel(Supplier<Bookmark> bookmarkSupplier)     // <.>
   Supplier<ManagedObject> asSupplier()
   T assertCompliance(T pojo)     // <.>
   String getTitle()     // <.>
-  Optional<ObjectSpecification> getElementSpecification()     // <.>
   String getIconName()     // <.>
   ObjectIcon getIcon()
+  Either<ManagedObject, ManagedObject> asEitherWithOrWithoutMemoizedBookmark()
   ManagedObject unspecified()     // <.>
   ManagedObject empty(ObjectSpecification spec)     // <.>
   ManagedObject value(ObjectSpecification spec, Object pojo)     // <.>
   ManagedObject service(ObjectSpecification spec, Object pojo)     // <.>
   ManagedObject viewmodel(ObjectSpecification spec, Object pojo, 
Optional<Bookmark> bookmarkIfKnown)     // <.>
   ManagedObject entity(ObjectSpecification spec, Object pojo, 
Optional<Bookmark> bookmarkIfKnown)     // <.>
-  ManagedObject entityAttached(ObjectSpecification spec, Object pojo, 
Optional<Bookmark> bookmarkIfKnown)
-  ManagedObject entityDetached(ObjectSpecification spec, Object pojo)
+  ManagedObject entityHypridBookmarked(ObjectSpecification spec, Object pojo, 
Optional<Bookmark> bookmarkIfKnown)
+  ManagedObject entityHybirdDetached(ObjectSpecification spec, Object pojo)
   ManagedObject mixin(ObjectSpecification spec, Object pojo)     // <.>
   ManagedObject other(ObjectSpecification spec, Object pojo)     // <.>
   PackedManagedObject packed(ObjectSpecification elementSpec, 
Can<ManagedObject> nonScalar)     // <.>
   ManagedObject adaptScalar(SpecificationLoader specLoader, Object pojo)     
// <.>
   ManagedObject adaptScalar(ObjectSpecification guess, Object pojo)
-  ManagedObject identified(ObjectSpecification spec, Object pojo, Bookmark 
bookmark)
-  ManagedObject adaptScalarInternal(ObjectSpecification guess, Object pojo, 
Optional<Bookmark> bookmarkIfAny)     // <.>
-  ManagedObject of(ObjectSpecification spec, Object pojo)     // <.>
   ManagedObject bookmarked(ObjectSpecification spec, Object pojo, Bookmark 
bookmark)     // <.>
+  ManagedObject adaptScalarInternal(ObjectSpecification guess, Object pojo, 
Optional<Bookmark> bookmarkIfAny)     // <.>
+  ManagedObject adaptParameter(ObjectActionParameter param, Object paramValue)
 }
 ----
 
@@ -56,11 +54,6 @@ Returns the specification that details the structure 
(meta-model) of this object
 --
 Returns the adapted domain object, the 'plain old java' object this managed 
object represents with the framework.
 --
-<.> xref:#refreshViewmodel_Supplier[refreshViewmodel(Supplier)]
-+
---
-If the underlying domain object is a viewmodel, refreshes any referenced 
entities. (Acts as a no-op otherwise.)
---
 <.> xref:#assertCompliance_T[assertCompliance(T)]
 +
 --
@@ -71,11 +64,6 @@ Unary operator asserting that _pojo_ and 
_#getSpecification()_ are compliant wit
 --
 The (untranslated) title of the wrapped pojo.
 --
-<.> xref:#getElementSpecification_[getElementSpecification()]
-+
---
-As used for the element type of collections.
---
 <.> xref:#getIconName_[getIconName()]
 +
 --
@@ -131,20 +119,15 @@ PACKED
 --
 For cases, when the pojo's specification is not available and needs to be 
looked up.
 --
-<.> 
xref:#adaptScalarInternal_ObjectSpecification_Object_Optional[adaptScalarInternal(ObjectSpecification,
 Object, Optional)]
-+
---
-spec and pojo don't need to be strictly in sync, we adapt if required
---
-<.> xref:#of_ObjectSpecification_Object[of(ObjectSpecification, Object)]
+<.> 
xref:#bookmarked_ObjectSpecification_Object_Bookmark[bookmarked(ObjectSpecification,
 Object, Bookmark)]
 +
 --
-Optimized for cases, when the pojo's specification is already available. If 
_pojo_ is an entity, automatically memoizes its bookmark.
+Optimized for cases, when the pojo's specification and bookmark are already 
available.
 --
-<.> 
xref:#bookmarked_ObjectSpecification_Object_Bookmark[bookmarked(ObjectSpecification,
 Object, Bookmark)]
+<.> 
xref:#adaptScalarInternal_ObjectSpecification_Object_Optional[adaptScalarInternal(ObjectSpecification,
 Object, Optional)]
 +
 --
-Optimized for cases, when the pojo's specification and bookmark are already 
available.
+spec and pojo don't need to be strictly in sync, we adapt if required
 --
 
 == Members
@@ -164,11 +147,6 @@ Returns the specification that details the structure 
(meta-model) of this object
 
 Returns the adapted domain object, the 'plain old java' object this managed 
object represents with the framework.
 
-[#refreshViewmodel_Supplier]
-=== refreshViewmodel(Supplier)
-
-If the underlying domain object is a viewmodel, refreshes any referenced 
entities. (Acts as a no-op otherwise.)
-
 [#assertCompliance_T]
 === assertCompliance(T)
 
@@ -179,11 +157,6 @@ Unary operator asserting that _pojo_ and 
_#getSpecification()_ are compliant wit
 
 The (untranslated) title of the wrapped pojo.
 
-[#getElementSpecification_]
-=== getElementSpecification()
-
-As used for the element type of collections.
-
 [#getIconName_]
 === getIconName()
 
@@ -243,17 +216,12 @@ For cases, when the pojo's specification is not available 
and needs to be looked
 
 Fails if the pojo is non-scalar.
 
-[#adaptScalarInternal_ObjectSpecification_Object_Optional]
-=== adaptScalarInternal(ObjectSpecification, Object, Optional)
-
-spec and pojo don't need to be strictly in sync, we adapt if required
-
-[#of_ObjectSpecification_Object]
-=== of(ObjectSpecification, Object)
-
-Optimized for cases, when the pojo's specification is already available. If 
_pojo_ is an entity, automatically memoizes its bookmark.
-
 [#bookmarked_ObjectSpecification_Object_Bookmark]
 === bookmarked(ObjectSpecification, Object, Bookmark)
 
 Optimized for cases, when the pojo's specification and bookmark are already 
available.
+
+[#adaptScalarInternal_ObjectSpecification_Object_Optional]
+=== adaptScalarInternal(ObjectSpecification, Object, Optional)
+
+spec and pojo don't need to be strictly in sync, we adapt if required
diff --git 
a/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/LifecycleCallbackNotifier.adoc
 
b/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/LifecycleCallbackNotifier.adoc
index 5fbe58bf9d..c2859618ae 100644
--- 
a/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/LifecycleCallbackNotifier.adoc
+++ 
b/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/LifecycleCallbackNotifier.adoc
@@ -11,7 +11,7 @@ Calls lifecycle callbacks for entities, ensuring that any 
given entity is only e
 class LifecycleCallbackNotifier {
   void postCreate(ManagedObject entity)
   void postLoad(ManagedObject entity)
-  void prePersist(ManagedObject entity)
+  void prePersist(Either<ManagedObject, ManagedObject> eitherWithOrWithoutOid) 
    // <.>
   void postPersist(ManagedObject entity)
   void preUpdate(ManagedObject entity)
   void postUpdate(ManagedObject entity)
@@ -19,3 +19,9 @@ class LifecycleCallbackNotifier {
 }
 ----
 
+<.> xref:#prePersist_Either[prePersist(Either)]
+
+== Members
+
+[#prePersist_Either]
+=== prePersist(Either)
diff --git 
a/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/ObjectLifecyclePublisherDefault.adoc
 
b/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/ObjectLifecyclePublisherDefault.adoc
index 81bd3f111e..92cb6801a4 100644
--- 
a/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/ObjectLifecyclePublisherDefault.adoc
+++ 
b/antora/components/refguide-index/modules/core/pages/index/runtimeservices/publish/ObjectLifecyclePublisherDefault.adoc
@@ -10,7 +10,7 @@ class ObjectLifecyclePublisherDefault {
   LifecycleCallbackNotifier lifecycleCallbackNotifier()
   void onPostCreate(ManagedObject entity)
   void onPostLoad(ManagedObject entity)
-  void onPrePersist(ManagedObject entity)
+  void onPrePersist(Either<ManagedObject, ManagedObject> 
eitherWithOrWithoutOid)
   void onPostPersist(ManagedObject entity)
   void onPreUpdate(ManagedObject entity, Can<PropertyChangeRecord> 
changeRecords)
   void onPostUpdate(ManagedObject entity)
diff --git a/core/adoc/modules/_overview/pages/about.adoc 
b/core/adoc/modules/_overview/pages/about.adoc
index c18c89b94e..f495450810 100644
--- a/core/adoc/modules/_overview/pages/about.adoc
+++ b/core/adoc/modules/_overview/pages/about.adoc
@@ -1702,7 +1702,7 @@ Directory: /core/runtime
 ****
 o.a.i.core.runtime.events.MetamodelEventService +
 o.a.i.core.runtime.events.TransactionEventEmitter +
-o.a.i.core.runtime.idstringifier.IdStringifierService +
+o.a.i.core.runtime.idstringifier.IdStringifierLookupService +
 ****
 
 .Dependencies

Reply via email to