mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-04-19 21:11:28 +07:00
[workspace model] IJPL-196541 Workspace generator fixes; Regenerate all IntelliJ workspace code
IJPL-895, IJPL-178663, IJPL-212395, IJPL-212407 Merge-request: IJ-MR-178140 Merged-by: Kirill Bochkarev <kirill.bochkarev@jetbrains.com> GitOrigin-RevId: 097f61d76f785db240a94046461d445d5497f605
This commit is contained in:
committed by
intellij-monorepo-bot
parent
2df765db1e
commit
eaa7c70266
@@ -12,46 +12,139 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeStringNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = true, type = "String")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.externalSystem.JavaBridgeCoordinateEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.java.impl.dependencySubstitution.LibraryMavenCoordinateEntity", entityDataFqName = "com.intellij.java.impl.dependencySubstitution.impl.LibraryMavenCoordinateEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "library", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.platform.workspace.jps.entities.LibraryEntity", isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "coordinates", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.java.library.MavenCoordinates", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "artifactId", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "baseVersion", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "classifier", valueType = primitiveTypeStringNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "groupId", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "packaging", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "version", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf())), withDefault = false)), extProperties = listOf(ExtPropertyMetadata(isComputable = false, isOpen = false, name = "mavenCoordinates", receiverFqn = "com.intellij.platform.workspace.jps.entities.LibraryEntity", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.java.impl.dependencySubstitution.LibraryMavenCoordinateEntity", isChild = true, isNullable = true), withDefault = false)), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.java.impl.dependencySubstitution.ModuleMavenCoordinateEntity", entityDataFqName = "com.intellij.java.impl.dependencySubstitution.impl.ModuleMavenCoordinateEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "module", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.platform.workspace.jps.entities.ModuleEntity", isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "coordinates", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.java.library.MavenCoordinates", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "artifactId", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "baseVersion", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "classifier", valueType = primitiveTypeStringNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "groupId", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "packaging", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "version", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf())), withDefault = false)), extProperties = listOf(ExtPropertyMetadata(isComputable = false, isOpen = false, name = "mavenCoordinates", receiverFqn = "com.intellij.platform.workspace.jps.entities.ModuleEntity", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.java.impl.dependencySubstitution.ModuleMavenCoordinateEntity", isChild = true, isNullable = true), withDefault = false)), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeStringNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = true, type = "String")
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.java.impl.dependencySubstitution.LibraryMavenCoordinateEntity", metadataHash = -1045210070)
|
||||
addMetadataHash(typeFqn = "com.intellij.java.impl.dependencySubstitution.ModuleMavenCoordinateEntity", metadataHash = -1563495236)
|
||||
addMetadataHash(typeFqn = "com.intellij.java.library.MavenCoordinates", metadataHash = -786961692)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -1889898909)
|
||||
addMetadataHash(typeFqn = "com.intellij.externalSystem.JavaBridgeCoordinateEntitySource", metadataHash = 1980250535)
|
||||
}
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.externalSystem.JavaBridgeCoordinateEntitySource",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.java.impl.dependencySubstitution.LibraryMavenCoordinateEntity",
|
||||
entityDataFqName = "com.intellij.java.impl.dependencySubstitution.impl.LibraryMavenCoordinateEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "library",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.platform.workspace.jps.entities.LibraryEntity",
|
||||
isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "coordinates",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.java.library.MavenCoordinates",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "artifactId",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false,
|
||||
name = "baseVersion",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "classifier",
|
||||
valueType = primitiveTypeStringNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "groupId",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "packaging",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "version",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf())), withDefault = false)),
|
||||
extProperties = listOf(
|
||||
ExtPropertyMetadata(isComputable = false, isOpen = false, name = "mavenCoordinates",
|
||||
receiverFqn = "com.intellij.platform.workspace.jps.entities.LibraryEntity",
|
||||
valueType = ValueTypeMetadata.EntityReference(
|
||||
connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.java.impl.dependencySubstitution.LibraryMavenCoordinateEntity",
|
||||
isChild = true, isNullable = true), withDefault = false)), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.java.impl.dependencySubstitution.ModuleMavenCoordinateEntity",
|
||||
entityDataFqName = "com.intellij.java.impl.dependencySubstitution.impl.ModuleMavenCoordinateEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "module",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.platform.workspace.jps.entities.ModuleEntity",
|
||||
isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "coordinates",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.java.library.MavenCoordinates",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "artifactId",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false,
|
||||
name = "baseVersion",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "classifier",
|
||||
valueType = primitiveTypeStringNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "groupId",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "packaging",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "version",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf())), withDefault = false)),
|
||||
extProperties = listOf(
|
||||
ExtPropertyMetadata(isComputable = false, isOpen = false, name = "mavenCoordinates",
|
||||
receiverFqn = "com.intellij.platform.workspace.jps.entities.ModuleEntity",
|
||||
valueType = ValueTypeMetadata.EntityReference(
|
||||
connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.java.impl.dependencySubstitution.ModuleMavenCoordinateEntity",
|
||||
isChild = true, isNullable = true), withDefault = false)), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.java.impl.dependencySubstitution.LibraryMavenCoordinateEntity", metadataHash = -1045210070)
|
||||
addMetadataHash(typeFqn = "com.intellij.java.impl.dependencySubstitution.ModuleMavenCoordinateEntity", metadataHash = -1563495236)
|
||||
addMetadataHash(typeFqn = "com.intellij.java.library.MavenCoordinates", metadataHash = -786961692)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -1889898909)
|
||||
addMetadataHash(typeFqn = "com.intellij.externalSystem.JavaBridgeCoordinateEntitySource", metadataHash = 1980250535)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -6,4 +6,4 @@ import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
import com.intellij.platform.workspace.storage.metadata.MetadataStorageBridge
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBridge(MetadataStorageImpl)
|
||||
internal object MetadataStorageImpl : MetadataStorageBridge(MetadataStorageImpl)
|
||||
|
||||
@@ -51,9 +51,7 @@ public interface LibraryMavenCoordinateEntity : WorkspaceEntity {
|
||||
public fun MutableEntityStorage.modifyLibraryMavenCoordinateEntity(
|
||||
entity: LibraryMavenCoordinateEntity,
|
||||
modification: LibraryMavenCoordinateEntity.Builder.() -> Unit,
|
||||
): LibraryMavenCoordinateEntity {
|
||||
return modifyEntity(LibraryMavenCoordinateEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): LibraryMavenCoordinateEntity = modifyEntity(LibraryMavenCoordinateEntity.Builder::class.java, entity, modification)
|
||||
|
||||
public var LibraryEntity.Builder.mavenCoordinates: LibraryMavenCoordinateEntity.Builder?
|
||||
by WorkspaceEntity.extensionBuilder(LibraryMavenCoordinateEntity::class.java)
|
||||
|
||||
@@ -51,9 +51,7 @@ public interface ModuleMavenCoordinateEntity : WorkspaceEntity {
|
||||
public fun MutableEntityStorage.modifyModuleMavenCoordinateEntity(
|
||||
entity: ModuleMavenCoordinateEntity,
|
||||
modification: ModuleMavenCoordinateEntity.Builder.() -> Unit,
|
||||
): ModuleMavenCoordinateEntity {
|
||||
return modifyEntity(ModuleMavenCoordinateEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ModuleMavenCoordinateEntity = modifyEntity(ModuleMavenCoordinateEntity.Builder::class.java, entity, modification)
|
||||
|
||||
public var ModuleEntity.Builder.mavenCoordinates: ModuleMavenCoordinateEntity.Builder?
|
||||
by WorkspaceEntity.extensionBuilder(ModuleMavenCoordinateEntity::class.java)
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.java.configurationStore.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
@@ -9,55 +10,239 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.java.configurationStore.SampleDummyParentCustomModuleEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "internalSource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = ExtendableClassMetadata.AbstractClassMetadata(fqName = "com.intellij.platform.workspace.jps.JpsFileEntitySource", subclasses = listOf(FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$FileInDirectory", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "directory", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "fileNameId", valueType = primitiveTypeIntNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectLocation", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.JpsFileEntitySource",
|
||||
"com.intellij.platform.workspace.jps.JpsProjectFileEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource")),
|
||||
FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.JpsGlobalFileEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "file", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.GlobalStorageEntitySource",
|
||||
"com.intellij.platform.workspace.jps.JpsFileEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource")),
|
||||
FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$ExactFile", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "file", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectLocation", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = ExtendableClassMetadata.AbstractClassMetadata(fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation", subclasses = listOf(FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$DirectoryBased", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "baseDirectoryUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "baseDirectoryUrlString", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "ideaFolder", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectDir", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectFilePath", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.JpsProjectConfigLocation")),
|
||||
FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$FileBased", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "baseDirectoryUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "baseDirectoryUrlString", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "iprFile", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "iprFileParent", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectFilePath", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.JpsProjectConfigLocation"))), supertypes = listOf())), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.JpsFileEntitySource",
|
||||
"com.intellij.platform.workspace.jps.JpsProjectFileEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.CustomModuleEntitySource",
|
||||
"com.intellij.platform.workspace.storage.DummyParentEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.java.configurationStore.SampleDummyParentCustomModuleEntitySource", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "internalSource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = ExtendableClassMetadata.AbstractClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsFileEntitySource",
|
||||
subclasses = listOf(FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$FileInDirectory",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "directory",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "fileNameId",
|
||||
valueType = primitiveTypeIntNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "projectLocation",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.JpsFileEntitySource",
|
||||
"com.intellij.platform.workspace.jps.JpsProjectFileEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource")),
|
||||
FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsGlobalFileEntitySource",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "file",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.GlobalStorageEntitySource",
|
||||
"com.intellij.platform.workspace.jps.JpsFileEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource")),
|
||||
FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$ExactFile",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "file",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "projectLocation",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = ExtendableClassMetadata.AbstractClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation",
|
||||
subclasses = listOf(
|
||||
FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$DirectoryBased",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "baseDirectoryUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "baseDirectoryUrlString",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "ideaFolder",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "projectDir",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "projectFilePath",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.JpsProjectConfigLocation")),
|
||||
FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$FileBased",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "baseDirectoryUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "baseDirectoryUrlString",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "iprFile",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "iprFileParent",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "projectFilePath",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.JpsProjectConfigLocation"))),
|
||||
supertypes = listOf())),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.JpsFileEntitySource",
|
||||
"com.intellij.platform.workspace.jps.JpsProjectFileEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.CustomModuleEntitySource",
|
||||
"com.intellij.platform.workspace.storage.DummyParentEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1833327951)
|
||||
addMetadataHash(typeFqn = "com.intellij.java.configurationStore.SampleDummyParentCustomModuleEntitySource", metadataHash = -462346181)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsFileEntitySource", metadataHash = 1441310205)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsGlobalFileEntitySource", metadataHash = -29934016)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource", metadataHash = -1393975338)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$ExactFile", metadataHash = -835143991)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation", metadataHash = -1739374703)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$DirectoryBased", metadataHash = 1161787715)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$FileBased", metadataHash = -2127607065)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$FileInDirectory", metadataHash = -1436516072)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1833327951)
|
||||
addMetadataHash(typeFqn = "com.intellij.java.configurationStore.SampleDummyParentCustomModuleEntitySource", metadataHash = -462346181)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsFileEntitySource", metadataHash = 1441310205)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsGlobalFileEntitySource", metadataHash = -29934016)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource", metadataHash = -1393975338)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$ExactFile", metadataHash = -835143991)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation", metadataHash = -1739374703)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$DirectoryBased", metadataHash = 1161787715)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectConfigLocation\$FileBased", metadataHash = -2127607065)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.JpsProjectFileEntitySource\$FileInDirectory", metadataHash = -1436516072)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
@file:ApiStatus.Internal
|
||||
package com.intellij.openapi.externalSystem.settings.workspaceModel.impl
|
||||
|
||||
@@ -16,8 +16,8 @@ import org.jetbrains.annotations.ApiStatus
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ExternalProjectsBuildClasspathEntityImpl(private val dataSource: ExternalProjectsBuildClasspathEntityData) :
|
||||
ExternalProjectsBuildClasspathEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class ExternalProjectsBuildClasspathEntityImpl(private val dataSource: ExternalProjectsBuildClasspathEntityData) : ExternalProjectsBuildClasspathEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
|
||||
@@ -44,9 +44,8 @@ internal class ExternalProjectsBuildClasspathEntityImpl(private val dataSource:
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ExternalProjectsBuildClasspathEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ExternalProjectsBuildClasspathEntity, ExternalProjectsBuildClasspathEntityData>(result),
|
||||
ExternalProjectsBuildClasspathEntity.Builder {
|
||||
internal class Builder(result: ExternalProjectsBuildClasspathEntityData?) : ModifiableWorkspaceEntityBase<ExternalProjectsBuildClasspathEntity, ExternalProjectsBuildClasspathEntityData>(
|
||||
result), ExternalProjectsBuildClasspathEntity.Builder {
|
||||
internal constructor() : this(ExternalProjectsBuildClasspathEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -90,8 +89,7 @@ internal class ExternalProjectsBuildClasspathEntityImpl(private val dataSource:
|
||||
override fun relabel(dataSource: WorkspaceEntity, parents: Set<WorkspaceEntity>?) {
|
||||
dataSource as ExternalProjectsBuildClasspathEntity
|
||||
if (this.entitySource != dataSource.entitySource) this.entitySource = dataSource.entitySource
|
||||
if (this.projectsBuildClasspath != dataSource.projectsBuildClasspath) this.projectsBuildClasspath =
|
||||
dataSource.projectsBuildClasspath.toMutableMap()
|
||||
if (this.projectsBuildClasspath != dataSource.projectsBuildClasspath) this.projectsBuildClasspath = dataSource.projectsBuildClasspath.toMutableMap()
|
||||
updateChildToParentReferences(parents)
|
||||
}
|
||||
|
||||
@@ -143,8 +141,7 @@ internal class ExternalProjectsBuildClasspathEntityData : WorkspaceEntityData<Ex
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.openapi.externalSystem.settings.workspaceModel.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
@@ -9,35 +10,106 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
val primitiveTypeMapNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Map")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
val primitiveTypeMapNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Map")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(
|
||||
fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntitySource",
|
||||
properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntity", entityDataFqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.impl.ExternalProjectsBuildClasspathEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectsBuildClasspath", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable,
|
||||
ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectBuildClasspathEntity", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "moduleBuildClasspath", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable,
|
||||
ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalModuleBuildClasspathEntity", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entries", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable), primitive = primitiveTypeListNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "path", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf()))), primitive = primitiveTypeMapNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectBuildClasspath", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable), primitive = primitiveTypeListNotNullable), withDefault = false)), supertypes = listOf()))), primitive = primitiveTypeMapNotNullable), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
typeMetadata = EntityMetadata(
|
||||
fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntity",
|
||||
entityDataFqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.impl.ExternalProjectsBuildClasspathEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "projectsBuildClasspath",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable,
|
||||
ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectBuildClasspathEntity",
|
||||
properties = listOf(OwnPropertyMetadata(
|
||||
isComputable = false, isKey = false,
|
||||
isOpen = false,
|
||||
name = "moduleBuildClasspath",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(
|
||||
generics = listOf(
|
||||
primitiveTypeStringNotNullable,
|
||||
ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalModuleBuildClasspathEntity",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "entries",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(
|
||||
generics = listOf(
|
||||
primitiveTypeStringNotNullable),
|
||||
primitive = primitiveTypeListNotNullable),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "path",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf()))),
|
||||
primitive = primitiveTypeMapNotNullable),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "projectBuildClasspath",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(
|
||||
generics = listOf(
|
||||
primitiveTypeStringNotNullable),
|
||||
primitive = primitiveTypeListNotNullable),
|
||||
withDefault = false)),
|
||||
supertypes = listOf()))),
|
||||
primitive = primitiveTypeMapNotNullable), withDefault = false)),
|
||||
extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntity", metadataHash = -2089661764)
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectBuildClasspathEntity", metadataHash = 1679465766)
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalModuleBuildClasspathEntity", metadataHash = 1440036197)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -632855931)
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntitySource", metadataHash = -872557435)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntity",
|
||||
metadataHash = -2089661764)
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectBuildClasspathEntity",
|
||||
metadataHash = 1679465766)
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalModuleBuildClasspathEntity",
|
||||
metadataHash = 1440036197)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -632855931)
|
||||
addMetadataHash(typeFqn = "com.intellij.openapi.externalSystem.settings.workspaceModel.ExternalProjectsBuildClasspathEntitySource",
|
||||
metadataHash = -872557435)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
@file:ApiStatus.Internal
|
||||
package com.intellij.openapi.externalSystem.settings.workspaceModel
|
||||
|
||||
@@ -40,9 +40,7 @@ interface ExternalProjectsBuildClasspathEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyExternalProjectsBuildClasspathEntity(
|
||||
entity: ExternalProjectsBuildClasspathEntity,
|
||||
modification: ExternalProjectsBuildClasspathEntity.Builder.() -> Unit,
|
||||
): ExternalProjectsBuildClasspathEntity {
|
||||
return modifyEntity(ExternalProjectsBuildClasspathEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ExternalProjectsBuildClasspathEntity = modifyEntity(ExternalProjectsBuildClasspathEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
data class ExternalModuleBuildClasspathEntity(val path: String, val entries: List<String>)
|
||||
|
||||
@@ -13,71 +13,246 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "codeCache", valueType = primitiveTypeIntNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "externalProjectPath", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntity", entityDataFqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.impl.DependencySubstitutionEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "owner", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_MANY, entityFqName = "com.intellij.platform.workspace.jps.entities.ModuleEntity", isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "library", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.entities.LibraryId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "codeCache", valueType = primitiveTypeIntNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "tableId", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = ExtendableClassMetadata.AbstractClassMetadata(fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId", subclasses = listOf(FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ProjectLibraryTableId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "level", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.entities.LibraryTableId",
|
||||
"java.io.Serializable")),
|
||||
FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$GlobalLibraryTableId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "level", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.entities.LibraryTableId",
|
||||
"java.io.Serializable")),
|
||||
FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ModuleLibraryTableId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "level", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "moduleId", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.entities.ModuleId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.entities.LibraryTableId",
|
||||
"java.io.Serializable"))), supertypes = listOf("java.io.Serializable"))), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "module", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.workspace.jps.entities.ModuleId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "scope", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.EnumClassMetadata(fqName = "com.intellij.platform.workspace.jps.entities.DependencyScope", properties = listOf(), supertypes = listOf("java.io.Serializable",
|
||||
"kotlin.Comparable",
|
||||
"kotlin.Enum"), values = listOf("COMPILE",
|
||||
"PROVIDED",
|
||||
"RUNTIME",
|
||||
"TEST"))), withDefault = false)), extProperties = listOf(ExtPropertyMetadata(isComputable = false, isOpen = false, name = "substitutions", receiverFqn = "com.intellij.platform.workspace.jps.entities.ModuleEntity", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_MANY, entityFqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntity", isChild = true, isNullable = false), withDefault = false)), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntity", entityDataFqName = "com.intellij.platform.externalSystem.impl.workspaceModel.impl.ExternalProjectEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity",
|
||||
"com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "externalProjectPath", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = true, isKey = false, isOpen = false, name = "symbolicId", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "codeCache", valueType = primitiveTypeIntNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "externalProjectPath", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntity", metadataHash = 1240680738)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntity", metadataHash = -586770816)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryId", metadataHash = 1192700660)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId", metadataHash = -219154451)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$GlobalLibraryTableId", metadataHash = 1911253865)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ModuleLibraryTableId", metadataHash = 777479370)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.ModuleId", metadataHash = -575206713)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ProjectLibraryTableId", metadataHash = -1574432194)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.DependencyScope", metadataHash = 1284754485)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntityId", metadataHash = -535054241)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -849218479)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntitySource", metadataHash = 1705395611)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.SymbolicEntityId", metadataHash = -1487098657)
|
||||
}
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(
|
||||
fqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntitySource", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntityId", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "codeCache",
|
||||
valueType = primitiveTypeIntNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "externalProjectPath",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntity",
|
||||
entityDataFqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.impl.DependencySubstitutionEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "owner",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_MANY,
|
||||
entityFqName = "com.intellij.platform.workspace.jps.entities.ModuleEntity",
|
||||
isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "library",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.LibraryId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "codeCache",
|
||||
valueType = primitiveTypeIntNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "tableId",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = ExtendableClassMetadata.AbstractClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId",
|
||||
subclasses = listOf(
|
||||
FinalClassMetadata.ObjectMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ProjectLibraryTableId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "level",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.entities.LibraryTableId",
|
||||
"java.io.Serializable")),
|
||||
FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$GlobalLibraryTableId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "level",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.entities.LibraryTableId",
|
||||
"java.io.Serializable")),
|
||||
FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ModuleLibraryTableId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "level",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "moduleId",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.ModuleId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.jps.entities.LibraryTableId",
|
||||
"java.io.Serializable"))),
|
||||
supertypes = listOf(
|
||||
"java.io.Serializable"))),
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "module",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.ModuleId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "scope",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.EnumClassMetadata(
|
||||
fqName = "com.intellij.platform.workspace.jps.entities.DependencyScope",
|
||||
properties = listOf(),
|
||||
supertypes = listOf("java.io.Serializable",
|
||||
"kotlin.Comparable",
|
||||
"kotlin.Enum"),
|
||||
values = listOf("COMPILE",
|
||||
"PROVIDED",
|
||||
"RUNTIME",
|
||||
"TEST"))), withDefault = false)),
|
||||
extProperties = listOf(ExtPropertyMetadata(isComputable = false, isOpen = false, name = "substitutions",
|
||||
receiverFqn = "com.intellij.platform.workspace.jps.entities.ModuleEntity",
|
||||
valueType = ValueTypeMetadata.EntityReference(
|
||||
connectionType = ConnectionId.ConnectionType.ONE_TO_MANY,
|
||||
entityFqName = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntity",
|
||||
isChild = true, isNullable = false), withDefault = false)),
|
||||
isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntity",
|
||||
entityDataFqName = "com.intellij.platform.externalSystem.impl.workspaceModel.impl.ExternalProjectEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity",
|
||||
"com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId"),
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "externalProjectPath",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = true, isKey = false, isOpen = false, name = "symbolicId",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntityId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "codeCache",
|
||||
valueType = primitiveTypeIntNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "externalProjectPath",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntity",
|
||||
metadataHash = 1240680738)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntity", metadataHash = -586770816)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryId", metadataHash = 1192700660)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId", metadataHash = -219154451)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$GlobalLibraryTableId",
|
||||
metadataHash = 1911253865)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ModuleLibraryTableId", metadataHash = 777479370)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.ModuleId", metadataHash = -575206713)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.LibraryTableId\$ProjectLibraryTableId",
|
||||
metadataHash = -1574432194)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.jps.entities.DependencyScope", metadataHash = 1284754485)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.workspaceModel.ExternalProjectEntityId", metadataHash = -535054241)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -849218479)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.externalSystem.impl.dependencySubstitution.DependencySubstitutionEntitySource",
|
||||
metadataHash = 1705395611)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.SymbolicEntityId", metadataHash = -1487098657)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -6,4 +6,4 @@ import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
import com.intellij.platform.workspace.storage.metadata.MetadataStorageBridge
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBridge(MetadataStorageImpl)
|
||||
internal object MetadataStorageImpl : MetadataStorageBridge(MetadataStorageImpl)
|
||||
|
||||
@@ -59,9 +59,7 @@ interface DependencySubstitutionEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyDependencySubstitutionEntity(
|
||||
entity: DependencySubstitutionEntity,
|
||||
modification: DependencySubstitutionEntity.Builder.() -> Unit,
|
||||
): DependencySubstitutionEntity {
|
||||
return modifyEntity(DependencySubstitutionEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): DependencySubstitutionEntity = modifyEntity(DependencySubstitutionEntity.Builder::class.java, entity, modification)
|
||||
|
||||
@get:Internal
|
||||
@set:Internal
|
||||
|
||||
@@ -43,7 +43,5 @@ interface ExternalProjectEntity: WorkspaceEntityWithSymbolicId {
|
||||
fun MutableEntityStorage.modifyExternalProjectEntity(
|
||||
entity: ExternalProjectEntity,
|
||||
modification: ExternalProjectEntity.Builder.() -> Unit,
|
||||
): ExternalProjectEntity {
|
||||
return modifyEntity(ExternalProjectEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ExternalProjectEntity = modifyEntity(ExternalProjectEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.ide.scratch.workspace.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
@@ -9,26 +10,47 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.ide.scratch.workspace.ScratchRootsEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.ide.scratch.workspace.ScratchRootsEntitySource",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.ide.scratch.workspace.ScratchRootsEntity", entityDataFqName = "com.intellij.ide.scratch.workspace.impl.ScratchRootsEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "roots", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl"))), primitive = primitiveTypeListNotNullable), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.ide.scratch.workspace.ScratchRootsEntity",
|
||||
entityDataFqName = "com.intellij.ide.scratch.workspace.impl.ScratchRootsEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "roots",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(
|
||||
ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl"))),
|
||||
primitive = primitiveTypeListNotNullable),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.ide.scratch.workspace.ScratchRootsEntity", metadataHash = -384535205)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1873376384)
|
||||
addMetadataHash(typeFqn = "com.intellij.ide.scratch.workspace.ScratchRootsEntitySource", metadataHash = 750435212)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.ide.scratch.workspace.ScratchRootsEntity", metadataHash = -384535205)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1873376384)
|
||||
addMetadataHash(typeFqn = "com.intellij.ide.scratch.workspace.ScratchRootsEntitySource", metadataHash = 750435212)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.ide.scratch.workspace.impl
|
||||
|
||||
import com.intellij.ide.scratch.workspace.ScratchRootsEntity
|
||||
@@ -23,8 +23,8 @@ import com.intellij.platform.workspace.storage.url.VirtualFileUrl
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ScratchRootsEntityImpl(private val dataSource: ScratchRootsEntityData) : ScratchRootsEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class ScratchRootsEntityImpl(private val dataSource: ScratchRootsEntityData) : ScratchRootsEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
|
||||
@@ -51,8 +51,8 @@ internal class ScratchRootsEntityImpl(private val dataSource: ScratchRootsEntity
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ScratchRootsEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ScratchRootsEntity, ScratchRootsEntityData>(result), ScratchRootsEntity.Builder {
|
||||
internal class Builder(result: ScratchRootsEntityData?) : ModifiableWorkspaceEntityBase<ScratchRootsEntity, ScratchRootsEntityData>(
|
||||
result), ScratchRootsEntity.Builder {
|
||||
internal constructor() : this(ScratchRootsEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.ide.scratch.workspace
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
@@ -42,9 +42,7 @@ interface ScratchRootsEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyScratchRootsEntity(
|
||||
entity: ScratchRootsEntity,
|
||||
modification: ScratchRootsEntity.Builder.() -> Unit,
|
||||
): ScratchRootsEntity {
|
||||
return modifyEntity(ScratchRootsEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ScratchRootsEntity = modifyEntity(ScratchRootsEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
internal object ScratchRootsEntitySource : EntitySource
|
||||
@@ -11,105 +11,330 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.util.indexing.testEntities.TestModuleEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.WithReferenceTestEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.ChildTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.ChildTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parent", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.util.indexing.testEntities.ParentTestEntity", isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "customChildProperty", valueType = primitiveTypeStringNotNullable, withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.IndexingTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.IndexingTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "roots", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl"))), primitive = primitiveTypeListNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "excludedRoots", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl"))), primitive = primitiveTypeListNotNullable), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.NonIndexableTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.NonIndexableTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "root", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.NonRecursiveTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.NonRecursiveTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "root", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.OneMoreWithReferenceTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.OneMoreWithReferenceTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "references", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.DependencyItem", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "reference", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false)), supertypes = listOf()))), primitive = primitiveTypeListNotNullable), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.ParentTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.ParentTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "child", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.util.indexing.testEntities.ChildTestEntity", isChild = true, isNullable = true), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "secondChild", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.util.indexing.testEntities.SiblingEntity", isChild = true, isNullable = true), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "customParentProperty", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parentEntityRoot", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.ReferredTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity",
|
||||
"com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "file", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = true, isKey = false, isOpen = false, name = "symbolicId", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.SiblingEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.SiblingEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parent", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE, entityFqName = "com.intellij.util.indexing.testEntities.ParentTestEntity", isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "customSiblingProperty", valueType = primitiveTypeStringNotNullable, withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.WithReferenceTestEntity", entityDataFqName = "com.intellij.util.indexing.testEntities.impl.WithReferenceTestEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity",
|
||||
"com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = true, isKey = false, isOpen = false, name = "symbolicId", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.WithReferenceTestEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "references", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.DependencyItem", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "reference", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "presentableName", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))), withDefault = false)), supertypes = listOf()))), primitive = primitiveTypeListNotNullable), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ChildTestEntity", metadataHash = -1326732737)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.IndexingTestEntity", metadataHash = -233870197)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.NonIndexableTestEntity", metadataHash = -15259978)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.NonRecursiveTestEntity", metadataHash = -55418454)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.OneMoreWithReferenceTestEntity", metadataHash = 55957801)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ParentTestEntity", metadataHash = 1278429366)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ReferredTestEntity", metadataHash = -241259566)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.SiblingEntity", metadataHash = 144691097)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.WithReferenceTestEntity", metadataHash = -2013557311)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.DependencyItem", metadataHash = -614614302)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ReferredTestEntityId", metadataHash = 443324880)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.WithReferenceTestEntityId", metadataHash = -168975238)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1279624819)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.TestModuleEntitySource", metadataHash = -1815413801)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.SymbolicEntityId", metadataHash = -1426179764)
|
||||
}
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.util.indexing.testEntities.TestModuleEntitySource",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "name", valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.util.indexing.testEntities.WithReferenceTestEntityId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "name", valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.SymbolicEntityId"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.ChildTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.ChildTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parent",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.util.indexing.testEntities.ParentTestEntity",
|
||||
isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "customChildProperty",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.IndexingTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.IndexingTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "roots",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(
|
||||
ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl"))),
|
||||
primitive = primitiveTypeListNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "excludedRoots",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(
|
||||
ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl"))),
|
||||
primitive = primitiveTypeListNotNullable),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.NonIndexableTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.NonIndexableTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "root",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.NonRecursiveTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.NonRecursiveTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "root",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.OneMoreWithReferenceTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.OneMoreWithReferenceTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "references",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(
|
||||
ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.util.indexing.testEntities.DependencyItem", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "reference",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false)), supertypes = listOf()))),
|
||||
primitive = primitiveTypeListNotNullable),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.ParentTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.ParentTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "child",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.util.indexing.testEntities.ChildTestEntity",
|
||||
isChild = true, isNullable = true), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "secondChild",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.util.indexing.testEntities.SiblingEntity",
|
||||
isChild = true, isNullable = true), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "customParentProperty",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parentEntityRoot",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.ReferredTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity",
|
||||
"com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId"),
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "file",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = true, isKey = false, isOpen = false, name = "symbolicId",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.SiblingEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.SiblingEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parent",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
entityFqName = "com.intellij.util.indexing.testEntities.ParentTestEntity",
|
||||
isChild = false, isNullable = false), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "customSiblingProperty",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.util.indexing.testEntities.WithReferenceTestEntity",
|
||||
entityDataFqName = "com.intellij.util.indexing.testEntities.impl.WithReferenceTestEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity",
|
||||
"com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId"),
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = true, isKey = false, isOpen = false, name = "symbolicId",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.util.indexing.testEntities.WithReferenceTestEntityId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false,
|
||||
isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "references",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(
|
||||
ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.util.indexing.testEntities.DependencyItem",
|
||||
properties = listOf(OwnPropertyMetadata(
|
||||
isComputable = false, isKey = false,
|
||||
isOpen = false, name = "reference",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.util.indexing.testEntities.ReferredTestEntityId",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(
|
||||
isComputable = false,
|
||||
isKey = false, isOpen = false,
|
||||
name = "presentableName",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf(
|
||||
"com.intellij.platform.workspace.storage.SymbolicEntityId"))),
|
||||
withDefault = false)),
|
||||
supertypes = listOf()))),
|
||||
primitive = primitiveTypeListNotNullable),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ChildTestEntity", metadataHash = -1326732737)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.IndexingTestEntity", metadataHash = -233870197)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.NonIndexableTestEntity", metadataHash = -15259978)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.NonRecursiveTestEntity", metadataHash = -55418454)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.OneMoreWithReferenceTestEntity", metadataHash = 55957801)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ParentTestEntity", metadataHash = 1278429366)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ReferredTestEntity", metadataHash = -241259566)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.SiblingEntity", metadataHash = 144691097)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.WithReferenceTestEntity", metadataHash = -2013557311)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.DependencyItem", metadataHash = -614614302)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.ReferredTestEntityId", metadataHash = 443324880)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.WithReferenceTestEntityId", metadataHash = -168975238)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1279624819)
|
||||
addMetadataHash(typeFqn = "com.intellij.util.indexing.testEntities.TestModuleEntitySource", metadataHash = -1815413801)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.SymbolicEntityId", metadataHash = -1426179764)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.util.indexing.testEntities
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
@@ -46,7 +46,5 @@ interface IndexingTestEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyIndexingTestEntity(
|
||||
entity: IndexingTestEntity,
|
||||
modification: IndexingTestEntity.Builder.() -> Unit,
|
||||
): IndexingTestEntity {
|
||||
return modifyEntity(IndexingTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): IndexingTestEntity = modifyEntity(IndexingTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -37,7 +37,5 @@ interface NonIndexableTestEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyNonIndexableTestEntity(
|
||||
entity: NonIndexableTestEntity,
|
||||
modification: NonIndexableTestEntity.Builder.() -> Unit,
|
||||
): NonIndexableTestEntity {
|
||||
return modifyEntity(NonIndexableTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): NonIndexableTestEntity = modifyEntity(NonIndexableTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -37,7 +37,5 @@ interface NonRecursiveTestEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyNonRecursiveTestEntity(
|
||||
entity: NonRecursiveTestEntity,
|
||||
modification: NonRecursiveTestEntity.Builder.() -> Unit,
|
||||
): NonRecursiveTestEntity {
|
||||
return modifyEntity(NonRecursiveTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): NonRecursiveTestEntity = modifyEntity(NonRecursiveTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.util.indexing.testEntities
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
@@ -51,9 +51,7 @@ interface ParentTestEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyParentTestEntity(
|
||||
entity: ParentTestEntity,
|
||||
modification: ParentTestEntity.Builder.() -> Unit,
|
||||
): ParentTestEntity {
|
||||
return modifyEntity(ParentTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ParentTestEntity = modifyEntity(ParentTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ChildTestEntity : WorkspaceEntity {
|
||||
@@ -92,9 +90,7 @@ interface ChildTestEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyChildTestEntity(
|
||||
entity: ChildTestEntity,
|
||||
modification: ChildTestEntity.Builder.() -> Unit,
|
||||
): ChildTestEntity {
|
||||
return modifyEntity(ChildTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ChildTestEntity = modifyEntity(ChildTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
/**
|
||||
@@ -137,7 +133,5 @@ interface SiblingEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifySiblingEntity(
|
||||
entity: SiblingEntity,
|
||||
modification: SiblingEntity.Builder.() -> Unit,
|
||||
): SiblingEntity {
|
||||
return modifyEntity(SiblingEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): SiblingEntity = modifyEntity(SiblingEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -57,9 +57,7 @@ interface OneMoreWithReferenceTestEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyOneMoreWithReferenceTestEntity(
|
||||
entity: OneMoreWithReferenceTestEntity,
|
||||
modification: OneMoreWithReferenceTestEntity.Builder.() -> Unit,
|
||||
): OneMoreWithReferenceTestEntity {
|
||||
return modifyEntity(OneMoreWithReferenceTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): OneMoreWithReferenceTestEntity = modifyEntity(OneMoreWithReferenceTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface WithReferenceTestEntity : WorkspaceEntityWithSymbolicId {
|
||||
@@ -103,9 +101,7 @@ interface WithReferenceTestEntity : WorkspaceEntityWithSymbolicId {
|
||||
fun MutableEntityStorage.modifyWithReferenceTestEntity(
|
||||
entity: WithReferenceTestEntity,
|
||||
modification: WithReferenceTestEntity.Builder.() -> Unit,
|
||||
): WithReferenceTestEntity {
|
||||
return modifyEntity(WithReferenceTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): WithReferenceTestEntity = modifyEntity(WithReferenceTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
|
||||
@@ -150,7 +146,5 @@ interface ReferredTestEntity : WorkspaceEntityWithSymbolicId {
|
||||
fun MutableEntityStorage.modifyReferredTestEntity(
|
||||
entity: ReferredTestEntity,
|
||||
modification: ReferredTestEntity.Builder.() -> Unit,
|
||||
): ReferredTestEntity {
|
||||
return modifyEntity(ReferredTestEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ReferredTestEntity = modifyEntity(ReferredTestEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.workspaceModel.ide.legacyBridge.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
@@ -8,24 +9,36 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.legacyBridge.ModuleDependencyIndexTest\$MySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(
|
||||
fqName = "com.intellij.workspaceModel.ide.legacyBridge.ModuleDependencyIndexTest\$MySource", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.legacyBridge.LibraryLevelsTrackerTest\$MySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(
|
||||
fqName = "com.intellij.workspaceModel.ide.legacyBridge.LibraryLevelsTrackerTest\$MySource", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -243875031)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.legacyBridge.LibraryLevelsTrackerTest\$MySource", metadataHash = -1911317467)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.legacyBridge.ModuleDependencyIndexTest\$MySource", metadataHash = -562697122)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -243875031)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.legacyBridge.LibraryLevelsTrackerTest\$MySource", metadataHash = -1911317467)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.legacyBridge.ModuleDependencyIndexTest\$MySource", metadataHash = -562697122)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -10,45 +10,45 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.Source", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.NonPersistentEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.ProjectRootEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.legacyBridge.ModuleDependencyIndexTest\$MySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.legacyBridge.LibraryLevelsTrackerTest\$MySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.ide.ProjectRootEntity", entityDataFqName = "com.intellij.workspaceModel.ide.impl.ProjectRootEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "root", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.ProjectRootEntity", metadataHash = -2042954686)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -243875031)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.NonPersistentEntitySource", metadataHash = 485749134)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.ProjectRootEntitySource", metadataHash = 544411415)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.Source", metadataHash = 1093972899)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.legacyBridge.LibraryLevelsTrackerTest\$MySource", metadataHash = -1911317467)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.legacyBridge.ModuleDependencyIndexTest\$MySource", metadataHash = -562697122)
|
||||
}
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.ProjectRootEntitySource",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.ide.ProjectRootEntity",
|
||||
entityDataFqName = "com.intellij.workspaceModel.ide.impl.ProjectRootEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "root",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.ProjectRootEntity", metadataHash = -2042954686)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1548610517)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.ProjectRootEntitySource", metadataHash = 544411415)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -83,7 +83,5 @@ interface ProjectRootEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyProjectRootEntity(
|
||||
entity: ProjectRootEntity,
|
||||
modification: ProjectRootEntity.Builder.() -> Unit,
|
||||
): ProjectRootEntity {
|
||||
return modifyEntity(ProjectRootEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ProjectRootEntity = modifyEntity(ProjectRootEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.workspaceModel.ide.impl.legacyBridge.library.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
import com.intellij.platform.workspace.storage.metadata.MetadataStorageBridge
|
||||
import com.intellij.platform.workspace.storage.metadata.impl.MetadataStorageBase
|
||||
import com.intellij.platform.workspace.storage.metadata.model.FinalClassMetadata
|
||||
import com.intellij.platform.workspace.storage.metadata.model.OwnPropertyMetadata
|
||||
@@ -8,22 +10,59 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.workspaceModel.ide.impl.legacyBridge.library.LegacyCustomLibraryEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "levelId", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.GlobalStorageEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.NonPersistentEntitySource",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false,
|
||||
name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(
|
||||
isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 298806520)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.impl.legacyBridge.library.LegacyCustomLibraryEntitySource", metadataHash = 965396052)
|
||||
}
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(
|
||||
fqName = "com.intellij.workspaceModel.ide.impl.legacyBridge.LegacyBridgeJpsEntitySourceFactoryImpl\$DummyParentEntitySourceForProjectSettings",
|
||||
properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)),
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.DummyParentEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.workspaceModel.ide.impl.legacyBridge.library.LegacyCustomLibraryEntitySource", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "levelId",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.jps.GlobalStorageEntitySource",
|
||||
"com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 298806520)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.NonPersistentEntitySource", metadataHash = 485749134)
|
||||
addMetadataHash(
|
||||
typeFqn = "com.intellij.workspaceModel.ide.impl.legacyBridge.LegacyBridgeJpsEntitySourceFactoryImpl\$DummyParentEntitySourceForProjectSettings",
|
||||
metadataHash = 780707301)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.impl.legacyBridge.library.LegacyCustomLibraryEntitySource",
|
||||
metadataHash = 965396052)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -33,23 +33,19 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ArchivePackagingElementEntityImpl(private val dataSource: ArchivePackagingElementEntityData) : ArchivePackagingElementEntity,
|
||||
WorkspaceEntityBase(
|
||||
dataSource
|
||||
) {
|
||||
internal class ArchivePackagingElementEntityImpl(private val dataSource: ArchivePackagingElementEntityData) : ArchivePackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ArtifactEntity::class.java, CompositePackagingElementEntity::class.java, ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true
|
||||
)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
CompositePackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -85,9 +81,8 @@ internal class ArchivePackagingElementEntityImpl(private val dataSource: Archive
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ArchivePackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ArchivePackagingElementEntity, ArchivePackagingElementEntityData>(result),
|
||||
ArchivePackagingElementEntity.Builder {
|
||||
internal class Builder(result: ArchivePackagingElementEntityData?) : ModifiableWorkspaceEntityBase<ArchivePackagingElementEntity, ArchivePackagingElementEntityData>(
|
||||
result), ArchivePackagingElementEntity.Builder {
|
||||
internal constructor() : this(ArchivePackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -161,17 +156,14 @@ internal class ArchivePackagingElementEntityImpl(private val dataSource: Archive
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -243,8 +235,8 @@ internal class ArchivePackagingElementEntityImpl(private val dataSource: Archive
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID, this)!!
|
||||
.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID,
|
||||
this)!!.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
(this.entityLinks[EntityLink(true, CHILDREN_CONNECTION_ID)] as? List<PackagingElementEntity.Builder<out PackagingElementEntity>>
|
||||
?: emptyList())
|
||||
}
|
||||
@@ -329,8 +321,7 @@ internal class ArchivePackagingElementEntityData : WorkspaceEntityData<ArchivePa
|
||||
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return ArchivePackagingElementEntity(fileName, entitySource) {
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.artifact = parents.filterIsInstance<ArtifactEntity.Builder>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,14 +36,16 @@ import org.jetbrains.annotations.NonNls
|
||||
internal class ArtifactEntityImpl(private val dataSource: ArtifactEntityData) : ArtifactEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val ROOTELEMENT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ArtifactEntity::class.java, CompositePackagingElementEntity::class.java, ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true
|
||||
)
|
||||
internal val CUSTOMPROPERTIES_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ArtifactEntity::class.java, ArtifactPropertiesEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val ARTIFACTOUTPUTPACKAGINGELEMENT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ArtifactEntity::class.java, ArtifactOutputPackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, true
|
||||
)
|
||||
internal val ROOTELEMENT_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
CompositePackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true)
|
||||
internal val CUSTOMPROPERTIES_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
ArtifactPropertiesEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val ARTIFACTOUTPUTPACKAGINGELEMENT_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
ArtifactOutputPackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE,
|
||||
true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
ROOTELEMENT_CONNECTION_ID,
|
||||
@@ -98,8 +100,8 @@ internal class ArtifactEntityImpl(private val dataSource: ArtifactEntityData) :
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ArtifactEntityData?) : ModifiableWorkspaceEntityBase<ArtifactEntity, ArtifactEntityData>(result),
|
||||
ArtifactEntity.Builder {
|
||||
internal class Builder(result: ArtifactEntityData?) : ModifiableWorkspaceEntityBase<ArtifactEntity, ArtifactEntityData>(
|
||||
result), ArtifactEntity.Builder {
|
||||
internal constructor() : this(ArtifactEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -214,17 +216,14 @@ internal class ArtifactEntityImpl(private val dataSource: ArtifactEntityData) :
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getOneChildBuilder(
|
||||
ROOTELEMENT_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
true, ROOTELEMENT_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getOneChildBuilder(ROOTELEMENT_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(true,
|
||||
ROOTELEMENT_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
true, ROOTELEMENT_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(true,
|
||||
ROOTELEMENT_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -259,8 +258,8 @@ internal class ArtifactEntityImpl(private val dataSource: ArtifactEntityData) :
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CUSTOMPROPERTIES_CONNECTION_ID, this)!!
|
||||
.toList() as List<ArtifactPropertiesEntity.Builder>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CUSTOMPROPERTIES_CONNECTION_ID,
|
||||
this)!!.toList() as List<ArtifactPropertiesEntity.Builder>) +
|
||||
(this.entityLinks[EntityLink(true, CUSTOMPROPERTIES_CONNECTION_ID)] as? List<ArtifactPropertiesEntity.Builder> ?: emptyList())
|
||||
}
|
||||
else {
|
||||
@@ -303,12 +302,10 @@ internal class ArtifactEntityImpl(private val dataSource: ArtifactEntityData) :
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getOneChildBuilder(
|
||||
ARTIFACTOUTPUTPACKAGINGELEMENT_CONNECTION_ID, this
|
||||
) as? ArtifactOutputPackagingElementEntity.Builder)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
true, ARTIFACTOUTPUTPACKAGINGELEMENT_CONNECTION_ID
|
||||
)] as? ArtifactOutputPackagingElementEntity.Builder)
|
||||
((_diff as MutableEntityStorageInstrumentation).getOneChildBuilder(ARTIFACTOUTPUTPACKAGINGELEMENT_CONNECTION_ID,
|
||||
this) as? ArtifactOutputPackagingElementEntity.Builder)
|
||||
?: (this.entityLinks[EntityLink(true,
|
||||
ARTIFACTOUTPUTPACKAGINGELEMENT_CONNECTION_ID)] as? ArtifactOutputPackagingElementEntity.Builder)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(true, ARTIFACTOUTPUTPACKAGINGELEMENT_CONNECTION_ID)] as? ArtifactOutputPackagingElementEntity.Builder
|
||||
|
||||
@@ -30,14 +30,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ArtifactOutputPackagingElementEntityImpl(private val dataSource: ArtifactOutputPackagingElementEntityData) :
|
||||
ArtifactOutputPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class ArtifactOutputPackagingElementEntityImpl(private val dataSource: ArtifactOutputPackagingElementEntityData) : ArtifactOutputPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -65,9 +64,8 @@ internal class ArtifactOutputPackagingElementEntityImpl(private val dataSource:
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ArtifactOutputPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ArtifactOutputPackagingElementEntity, ArtifactOutputPackagingElementEntityData>(result),
|
||||
ArtifactOutputPackagingElementEntity.Builder {
|
||||
internal class Builder(result: ArtifactOutputPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<ArtifactOutputPackagingElementEntity, ArtifactOutputPackagingElementEntityData>(
|
||||
result), ArtifactOutputPackagingElementEntity.Builder {
|
||||
internal constructor() : this(ArtifactOutputPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -127,17 +125,14 @@ internal class ArtifactOutputPackagingElementEntityImpl(private val dataSource:
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -258,8 +253,7 @@ internal class ArtifactOutputPackagingElementEntityData : WorkspaceEntityData<Ar
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.ArtifactOutputPackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.ArtifactOutputPackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -269,8 +263,7 @@ internal class ArtifactOutputPackagingElementEntityData : WorkspaceEntityData<Ar
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return ArtifactOutputPackagingElementEntity(entitySource) {
|
||||
this.artifact = this@ArtifactOutputPackagingElementEntityData.artifact
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -26,12 +26,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ArtifactPropertiesEntityImpl(private val dataSource: ArtifactPropertiesEntityData) : ArtifactPropertiesEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class ArtifactPropertiesEntityImpl(private val dataSource: ArtifactPropertiesEntityData) : ArtifactPropertiesEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ArtifactEntity::class.java, ArtifactPropertiesEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
ArtifactPropertiesEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
ARTIFACT_CONNECTION_ID,
|
||||
@@ -65,8 +66,8 @@ internal class ArtifactPropertiesEntityImpl(private val dataSource: ArtifactProp
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ArtifactPropertiesEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ArtifactPropertiesEntity, ArtifactPropertiesEntityData>(result), ArtifactPropertiesEntity.Builder {
|
||||
internal class Builder(result: ArtifactPropertiesEntityData?) : ModifiableWorkspaceEntityBase<ArtifactPropertiesEntity, ArtifactPropertiesEntityData>(
|
||||
result), ArtifactPropertiesEntity.Builder {
|
||||
internal constructor() : this(ArtifactPropertiesEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -33,21 +33,19 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ArtifactRootElementEntityImpl(private val dataSource: ArtifactRootElementEntityData) : ArtifactRootElementEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class ArtifactRootElementEntityImpl(private val dataSource: ArtifactRootElementEntityData) : ArtifactRootElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ArtifactEntity::class.java, CompositePackagingElementEntity::class.java, ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true
|
||||
)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
CompositePackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -77,8 +75,8 @@ internal class ArtifactRootElementEntityImpl(private val dataSource: ArtifactRoo
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ArtifactRootElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ArtifactRootElementEntity, ArtifactRootElementEntityData>(result), ArtifactRootElementEntity.Builder {
|
||||
internal class Builder(result: ArtifactRootElementEntityData?) : ModifiableWorkspaceEntityBase<ArtifactRootElementEntity, ArtifactRootElementEntityData>(
|
||||
result), ArtifactRootElementEntity.Builder {
|
||||
internal constructor() : this(ArtifactRootElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -148,17 +146,14 @@ internal class ArtifactRootElementEntityImpl(private val dataSource: ArtifactRoo
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -230,8 +225,8 @@ internal class ArtifactRootElementEntityImpl(private val dataSource: ArtifactRoo
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID, this)!!
|
||||
.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID,
|
||||
this)!!.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
(this.entityLinks[EntityLink(true, CHILDREN_CONNECTION_ID)] as? List<PackagingElementEntity.Builder<out PackagingElementEntity>>
|
||||
?: emptyList())
|
||||
}
|
||||
@@ -306,8 +301,7 @@ internal class ArtifactRootElementEntityData : WorkspaceEntityData<ArtifactRootE
|
||||
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return ArtifactRootElementEntity(entitySource) {
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.artifact = parents.filterIsInstance<ArtifactEntity.Builder>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,8 +22,8 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ArtifactsOrderEntityImpl(private val dataSource: ArtifactsOrderEntityData) : ArtifactsOrderEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class ArtifactsOrderEntityImpl(private val dataSource: ArtifactsOrderEntityData) : ArtifactsOrderEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
|
||||
@@ -50,8 +50,8 @@ internal class ArtifactsOrderEntityImpl(private val dataSource: ArtifactsOrderEn
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ArtifactsOrderEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ArtifactsOrderEntity, ArtifactsOrderEntityData>(result), ArtifactsOrderEntity.Builder {
|
||||
internal class Builder(result: ArtifactsOrderEntityData?) : ModifiableWorkspaceEntityBase<ArtifactsOrderEntity, ArtifactsOrderEntityData>(
|
||||
result), ArtifactsOrderEntity.Builder {
|
||||
internal constructor() : this(ArtifactsOrderEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -33,23 +33,19 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class CustomPackagingElementEntityImpl(private val dataSource: CustomPackagingElementEntityData) : CustomPackagingElementEntity,
|
||||
WorkspaceEntityBase(
|
||||
dataSource
|
||||
) {
|
||||
internal class CustomPackagingElementEntityImpl(private val dataSource: CustomPackagingElementEntityData) : CustomPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ArtifactEntity::class.java, CompositePackagingElementEntity::class.java, ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true
|
||||
)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
CompositePackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -91,9 +87,8 @@ internal class CustomPackagingElementEntityImpl(private val dataSource: CustomPa
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: CustomPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<CustomPackagingElementEntity, CustomPackagingElementEntityData>(result),
|
||||
CustomPackagingElementEntity.Builder {
|
||||
internal class Builder(result: CustomPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<CustomPackagingElementEntity, CustomPackagingElementEntityData>(
|
||||
result), CustomPackagingElementEntity.Builder {
|
||||
internal constructor() : this(CustomPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -171,17 +166,14 @@ internal class CustomPackagingElementEntityImpl(private val dataSource: CustomPa
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -253,8 +245,8 @@ internal class CustomPackagingElementEntityImpl(private val dataSource: CustomPa
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID, this)!!
|
||||
.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID,
|
||||
this)!!.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
(this.entityLinks[EntityLink(true, CHILDREN_CONNECTION_ID)] as? List<PackagingElementEntity.Builder<out PackagingElementEntity>>
|
||||
?: emptyList())
|
||||
}
|
||||
@@ -349,8 +341,7 @@ internal class CustomPackagingElementEntityData : WorkspaceEntityData<CustomPack
|
||||
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return CustomPackagingElementEntity(typeId, propertiesXmlTag, entitySource) {
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.artifact = parents.filterIsInstance<ArtifactEntity.Builder>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,14 +27,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class DirectoryCopyPackagingElementEntityImpl(private val dataSource: DirectoryCopyPackagingElementEntityData) :
|
||||
DirectoryCopyPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class DirectoryCopyPackagingElementEntityImpl(private val dataSource: DirectoryCopyPackagingElementEntityData) : DirectoryCopyPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -62,9 +61,8 @@ internal class DirectoryCopyPackagingElementEntityImpl(private val dataSource: D
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: DirectoryCopyPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<DirectoryCopyPackagingElementEntity, DirectoryCopyPackagingElementEntityData>(result),
|
||||
DirectoryCopyPackagingElementEntity.Builder {
|
||||
internal class Builder(result: DirectoryCopyPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<DirectoryCopyPackagingElementEntity, DirectoryCopyPackagingElementEntityData>(
|
||||
result), DirectoryCopyPackagingElementEntity.Builder {
|
||||
internal constructor() : this(DirectoryCopyPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -127,17 +125,14 @@ internal class DirectoryCopyPackagingElementEntityImpl(private val dataSource: D
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -208,8 +203,7 @@ internal class DirectoryCopyPackagingElementEntityData : WorkspaceEntityData<Dir
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.DirectoryCopyPackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.DirectoryCopyPackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -218,8 +212,7 @@ internal class DirectoryCopyPackagingElementEntityData : WorkspaceEntityData<Dir
|
||||
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return DirectoryCopyPackagingElementEntity(filePath, entitySource) {
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -33,21 +33,19 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class DirectoryPackagingElementEntityImpl(private val dataSource: DirectoryPackagingElementEntityData) :
|
||||
DirectoryPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class DirectoryPackagingElementEntityImpl(private val dataSource: DirectoryPackagingElementEntityData) : DirectoryPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ArtifactEntity::class.java, CompositePackagingElementEntity::class.java, ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true
|
||||
)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
internal val ARTIFACT_CONNECTION_ID: ConnectionId = ConnectionId.create(ArtifactEntity::class.java,
|
||||
CompositePackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ABSTRACT_ONE_TO_ONE, true)
|
||||
internal val CHILDREN_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -83,9 +81,8 @@ internal class DirectoryPackagingElementEntityImpl(private val dataSource: Direc
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: DirectoryPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<DirectoryPackagingElementEntity, DirectoryPackagingElementEntityData>(result),
|
||||
DirectoryPackagingElementEntity.Builder {
|
||||
internal class Builder(result: DirectoryPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<DirectoryPackagingElementEntity, DirectoryPackagingElementEntityData>(
|
||||
result), DirectoryPackagingElementEntity.Builder {
|
||||
internal constructor() : this(DirectoryPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -159,17 +156,14 @@ internal class DirectoryPackagingElementEntityImpl(private val dataSource: Direc
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -241,8 +235,8 @@ internal class DirectoryPackagingElementEntityImpl(private val dataSource: Direc
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID, this)!!
|
||||
.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDREN_CONNECTION_ID,
|
||||
this)!!.toList() as List<PackagingElementEntity.Builder<out PackagingElementEntity>>) +
|
||||
(this.entityLinks[EntityLink(true, CHILDREN_CONNECTION_ID)] as? List<PackagingElementEntity.Builder<out PackagingElementEntity>>
|
||||
?: emptyList())
|
||||
}
|
||||
@@ -319,8 +313,7 @@ internal class DirectoryPackagingElementEntityData : WorkspaceEntityData<Directo
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.DirectoryPackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.DirectoryPackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -329,8 +322,7 @@ internal class DirectoryPackagingElementEntityData : WorkspaceEntityData<Directo
|
||||
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return DirectoryPackagingElementEntity(directoryName, entitySource) {
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.artifact = parents.filterIsInstance<ArtifactEntity.Builder>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -27,14 +27,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ExtractedDirectoryPackagingElementEntityImpl(private val dataSource: ExtractedDirectoryPackagingElementEntityData) :
|
||||
ExtractedDirectoryPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class ExtractedDirectoryPackagingElementEntityImpl(private val dataSource: ExtractedDirectoryPackagingElementEntityData) : ExtractedDirectoryPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -68,9 +67,8 @@ internal class ExtractedDirectoryPackagingElementEntityImpl(private val dataSour
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ExtractedDirectoryPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ExtractedDirectoryPackagingElementEntity, ExtractedDirectoryPackagingElementEntityData>(result),
|
||||
ExtractedDirectoryPackagingElementEntity.Builder {
|
||||
internal class Builder(result: ExtractedDirectoryPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<ExtractedDirectoryPackagingElementEntity, ExtractedDirectoryPackagingElementEntityData>(
|
||||
result), ExtractedDirectoryPackagingElementEntity.Builder {
|
||||
internal constructor() : this(ExtractedDirectoryPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -137,17 +135,14 @@ internal class ExtractedDirectoryPackagingElementEntityImpl(private val dataSour
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -228,8 +223,7 @@ internal class ExtractedDirectoryPackagingElementEntityData : WorkspaceEntityDat
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.ExtractedDirectoryPackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.ExtractedDirectoryPackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -238,8 +232,7 @@ internal class ExtractedDirectoryPackagingElementEntityData : WorkspaceEntityDat
|
||||
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return ExtractedDirectoryPackagingElementEntity(filePath, pathInArchive, entitySource) {
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -27,14 +27,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class FileCopyPackagingElementEntityImpl(private val dataSource: FileCopyPackagingElementEntityData) :
|
||||
FileCopyPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class FileCopyPackagingElementEntityImpl(private val dataSource: FileCopyPackagingElementEntityData) : FileCopyPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -68,9 +67,8 @@ internal class FileCopyPackagingElementEntityImpl(private val dataSource: FileCo
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: FileCopyPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<FileCopyPackagingElementEntity, FileCopyPackagingElementEntityData>(result),
|
||||
FileCopyPackagingElementEntity.Builder {
|
||||
internal class Builder(result: FileCopyPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<FileCopyPackagingElementEntity, FileCopyPackagingElementEntityData>(
|
||||
result), FileCopyPackagingElementEntity.Builder {
|
||||
internal constructor() : this(FileCopyPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -134,17 +132,14 @@ internal class FileCopyPackagingElementEntityImpl(private val dataSource: FileCo
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -233,8 +228,7 @@ internal class FileCopyPackagingElementEntityData : WorkspaceEntityData<FileCopy
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return FileCopyPackagingElementEntity(filePath, entitySource) {
|
||||
this.renamedOutputFileName = this@FileCopyPackagingElementEntityData.renamedOutputFileName
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -29,12 +29,12 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class JavaModuleSettingsEntityImpl(private val dataSource: JavaModuleSettingsEntityData) : JavaModuleSettingsEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class JavaModuleSettingsEntityImpl(private val dataSource: JavaModuleSettingsEntityData) : JavaModuleSettingsEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, JavaModuleSettingsEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, JavaModuleSettingsEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULE_CONNECTION_ID,
|
||||
@@ -86,8 +86,8 @@ internal class JavaModuleSettingsEntityImpl(private val dataSource: JavaModuleSe
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: JavaModuleSettingsEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<JavaModuleSettingsEntity, JavaModuleSettingsEntityData>(result), JavaModuleSettingsEntity.Builder {
|
||||
internal class Builder(result: JavaModuleSettingsEntityData?) : ModifiableWorkspaceEntityBase<JavaModuleSettingsEntity, JavaModuleSettingsEntityData>(
|
||||
result), JavaModuleSettingsEntity.Builder {
|
||||
internal constructor() : this(JavaModuleSettingsEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -140,8 +140,7 @@ internal class JavaModuleSettingsEntityImpl(private val dataSource: JavaModuleSe
|
||||
override fun relabel(dataSource: WorkspaceEntity, parents: Set<WorkspaceEntity>?) {
|
||||
dataSource as JavaModuleSettingsEntity
|
||||
if (this.entitySource != dataSource.entitySource) this.entitySource = dataSource.entitySource
|
||||
if (this.inheritedCompilerOutput != dataSource.inheritedCompilerOutput) this.inheritedCompilerOutput =
|
||||
dataSource.inheritedCompilerOutput
|
||||
if (this.inheritedCompilerOutput != dataSource.inheritedCompilerOutput) this.inheritedCompilerOutput = dataSource.inheritedCompilerOutput
|
||||
if (this.excludeOutput != dataSource.excludeOutput) this.excludeOutput = dataSource.excludeOutput
|
||||
if (this.compilerOutput != dataSource?.compilerOutput) this.compilerOutput = dataSource.compilerOutput
|
||||
if (this.compilerOutputForTests != dataSource?.compilerOutputForTests) this.compilerOutputForTests = dataSource.compilerOutputForTests
|
||||
|
||||
@@ -27,13 +27,13 @@ import com.intellij.platform.workspace.storage.metadata.model.EntityMetadata
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class JavaResourceRootPropertiesEntityImpl(private val dataSource: JavaResourceRootPropertiesEntityData) :
|
||||
JavaResourceRootPropertiesEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class JavaResourceRootPropertiesEntityImpl(private val dataSource: JavaResourceRootPropertiesEntityData) : JavaResourceRootPropertiesEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val SOURCEROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
SourceRootEntity::class.java, JavaResourceRootPropertiesEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false
|
||||
)
|
||||
internal val SOURCEROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(SourceRootEntity::class.java,
|
||||
JavaResourceRootPropertiesEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
SOURCEROOT_CONNECTION_ID,
|
||||
@@ -66,9 +66,8 @@ internal class JavaResourceRootPropertiesEntityImpl(private val dataSource: Java
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: JavaResourceRootPropertiesEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<JavaResourceRootPropertiesEntity, JavaResourceRootPropertiesEntityData>(result),
|
||||
JavaResourceRootPropertiesEntity.Builder {
|
||||
internal class Builder(result: JavaResourceRootPropertiesEntityData?) : ModifiableWorkspaceEntityBase<JavaResourceRootPropertiesEntity, JavaResourceRootPropertiesEntityData>(
|
||||
result), JavaResourceRootPropertiesEntity.Builder {
|
||||
internal constructor() : this(JavaResourceRootPropertiesEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -225,8 +224,7 @@ internal class JavaResourceRootPropertiesEntityData : WorkspaceEntityData<JavaRe
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.JavaResourceRootPropertiesEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.JavaResourceRootPropertiesEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
|
||||
@@ -27,13 +27,13 @@ import com.intellij.platform.workspace.storage.metadata.model.EntityMetadata
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class JavaSourceRootPropertiesEntityImpl(private val dataSource: JavaSourceRootPropertiesEntityData) :
|
||||
JavaSourceRootPropertiesEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class JavaSourceRootPropertiesEntityImpl(private val dataSource: JavaSourceRootPropertiesEntityData) : JavaSourceRootPropertiesEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val SOURCEROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
SourceRootEntity::class.java, JavaSourceRootPropertiesEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false
|
||||
)
|
||||
internal val SOURCEROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(SourceRootEntity::class.java,
|
||||
JavaSourceRootPropertiesEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
SOURCEROOT_CONNECTION_ID,
|
||||
@@ -66,9 +66,8 @@ internal class JavaSourceRootPropertiesEntityImpl(private val dataSource: JavaSo
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: JavaSourceRootPropertiesEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<JavaSourceRootPropertiesEntity, JavaSourceRootPropertiesEntityData>(result),
|
||||
JavaSourceRootPropertiesEntity.Builder {
|
||||
internal class Builder(result: JavaSourceRootPropertiesEntityData?) : ModifiableWorkspaceEntityBase<JavaSourceRootPropertiesEntity, JavaSourceRootPropertiesEntityData>(
|
||||
result), JavaSourceRootPropertiesEntity.Builder {
|
||||
internal constructor() : this(JavaSourceRootPropertiesEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -29,14 +29,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class LibraryFilesPackagingElementEntityImpl(private val dataSource: LibraryFilesPackagingElementEntityData) :
|
||||
LibraryFilesPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class LibraryFilesPackagingElementEntityImpl(private val dataSource: LibraryFilesPackagingElementEntityData) : LibraryFilesPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -64,9 +63,8 @@ internal class LibraryFilesPackagingElementEntityImpl(private val dataSource: Li
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: LibraryFilesPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<LibraryFilesPackagingElementEntity, LibraryFilesPackagingElementEntityData>(result),
|
||||
LibraryFilesPackagingElementEntity.Builder {
|
||||
internal class Builder(result: LibraryFilesPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<LibraryFilesPackagingElementEntity, LibraryFilesPackagingElementEntityData>(
|
||||
result), LibraryFilesPackagingElementEntity.Builder {
|
||||
internal constructor() : this(LibraryFilesPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -126,17 +124,14 @@ internal class LibraryFilesPackagingElementEntityImpl(private val dataSource: Li
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -257,8 +252,7 @@ internal class LibraryFilesPackagingElementEntityData : WorkspaceEntityData<Libr
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.LibraryFilesPackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.LibraryFilesPackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -268,8 +262,7 @@ internal class LibraryFilesPackagingElementEntityData : WorkspaceEntityData<Libr
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return LibraryFilesPackagingElementEntity(entitySource) {
|
||||
this.library = this@LibraryFilesPackagingElementEntityData.library
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -29,14 +29,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ModuleOutputPackagingElementEntityImpl(private val dataSource: ModuleOutputPackagingElementEntityData) :
|
||||
ModuleOutputPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class ModuleOutputPackagingElementEntityImpl(private val dataSource: ModuleOutputPackagingElementEntityData) : ModuleOutputPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -64,9 +63,8 @@ internal class ModuleOutputPackagingElementEntityImpl(private val dataSource: Mo
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ModuleOutputPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ModuleOutputPackagingElementEntity, ModuleOutputPackagingElementEntityData>(result),
|
||||
ModuleOutputPackagingElementEntity.Builder {
|
||||
internal class Builder(result: ModuleOutputPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<ModuleOutputPackagingElementEntity, ModuleOutputPackagingElementEntityData>(
|
||||
result), ModuleOutputPackagingElementEntity.Builder {
|
||||
internal constructor() : this(ModuleOutputPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -126,17 +124,14 @@ internal class ModuleOutputPackagingElementEntityImpl(private val dataSource: Mo
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -257,8 +252,7 @@ internal class ModuleOutputPackagingElementEntityData : WorkspaceEntityData<Modu
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.ModuleOutputPackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.ModuleOutputPackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -268,8 +262,7 @@ internal class ModuleOutputPackagingElementEntityData : WorkspaceEntityData<Modu
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return ModuleOutputPackagingElementEntity(entitySource) {
|
||||
this.module = this@ModuleOutputPackagingElementEntityData.module
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -29,14 +29,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ModuleSourcePackagingElementEntityImpl(private val dataSource: ModuleSourcePackagingElementEntityData) :
|
||||
ModuleSourcePackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class ModuleSourcePackagingElementEntityImpl(private val dataSource: ModuleSourcePackagingElementEntityData) : ModuleSourcePackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -64,9 +63,8 @@ internal class ModuleSourcePackagingElementEntityImpl(private val dataSource: Mo
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ModuleSourcePackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ModuleSourcePackagingElementEntity, ModuleSourcePackagingElementEntityData>(result),
|
||||
ModuleSourcePackagingElementEntity.Builder {
|
||||
internal class Builder(result: ModuleSourcePackagingElementEntityData?) : ModifiableWorkspaceEntityBase<ModuleSourcePackagingElementEntity, ModuleSourcePackagingElementEntityData>(
|
||||
result), ModuleSourcePackagingElementEntity.Builder {
|
||||
internal constructor() : this(ModuleSourcePackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -126,17 +124,14 @@ internal class ModuleSourcePackagingElementEntityImpl(private val dataSource: Mo
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -257,8 +252,7 @@ internal class ModuleSourcePackagingElementEntityData : WorkspaceEntityData<Modu
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.ModuleSourcePackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.ModuleSourcePackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -268,8 +262,7 @@ internal class ModuleSourcePackagingElementEntityData : WorkspaceEntityData<Modu
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return ModuleSourcePackagingElementEntity(entitySource) {
|
||||
this.module = this@ModuleSourcePackagingElementEntityData.module
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -29,14 +29,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ModuleTestOutputPackagingElementEntityImpl(private val dataSource: ModuleTestOutputPackagingElementEntityData) :
|
||||
ModuleTestOutputPackagingElementEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class ModuleTestOutputPackagingElementEntityImpl(private val dataSource: ModuleTestOutputPackagingElementEntityData) : ModuleTestOutputPackagingElementEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
CompositePackagingElementEntity::class.java, PackagingElementEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY,
|
||||
true
|
||||
)
|
||||
internal val PARENTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(CompositePackagingElementEntity::class.java,
|
||||
PackagingElementEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ABSTRACT_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENTENTITY_CONNECTION_ID,
|
||||
@@ -64,9 +63,8 @@ internal class ModuleTestOutputPackagingElementEntityImpl(private val dataSource
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ModuleTestOutputPackagingElementEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ModuleTestOutputPackagingElementEntity, ModuleTestOutputPackagingElementEntityData>(result),
|
||||
ModuleTestOutputPackagingElementEntity.Builder {
|
||||
internal class Builder(result: ModuleTestOutputPackagingElementEntityData?) : ModifiableWorkspaceEntityBase<ModuleTestOutputPackagingElementEntity, ModuleTestOutputPackagingElementEntityData>(
|
||||
result), ModuleTestOutputPackagingElementEntity.Builder {
|
||||
internal constructor() : this(ModuleTestOutputPackagingElementEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -126,17 +124,14 @@ internal class ModuleTestOutputPackagingElementEntityImpl(private val dataSource
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENTENTITY_CONNECTION_ID, this
|
||||
) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENTENTITY_CONNECTION_ID,
|
||||
this) as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
?: (this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>)
|
||||
}
|
||||
else {
|
||||
this.entityLinks[EntityLink(
|
||||
false, PARENTENTITY_CONNECTION_ID
|
||||
)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
this.entityLinks[EntityLink(false,
|
||||
PARENTENTITY_CONNECTION_ID)] as? CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>
|
||||
}
|
||||
}
|
||||
set(value) {
|
||||
@@ -257,8 +252,7 @@ internal class ModuleTestOutputPackagingElementEntityData : WorkspaceEntityData<
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.java.workspace.entities.ModuleTestOutputPackagingElementEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.java.workspace.entities.ModuleTestOutputPackagingElementEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
@@ -268,8 +262,7 @@ internal class ModuleTestOutputPackagingElementEntityData : WorkspaceEntityData<
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return ModuleTestOutputPackagingElementEntity(entitySource) {
|
||||
this.module = this@ModuleTestOutputPackagingElementEntityData.module
|
||||
this.parentEntity =
|
||||
parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
this.parentEntity = parents.filterIsInstance<CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>>().singleOrNull()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -32,12 +32,12 @@ import org.jetbrains.annotations.NonNls
|
||||
internal class ContentRootEntityImpl(private val dataSource: ContentRootEntityData) : ContentRootEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, ContentRootEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val SOURCEROOTS_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ContentRootEntity::class.java, SourceRootEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val EXCLUDEDURLS_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ContentRootEntity::class.java, ExcludeUrlEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, true)
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, ContentRootEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val SOURCEROOTS_CONNECTION_ID: ConnectionId = ConnectionId.create(ContentRootEntity::class.java, SourceRootEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val EXCLUDEDURLS_CONNECTION_ID: ConnectionId = ConnectionId.create(ContentRootEntity::class.java, ExcludeUrlEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULE_CONNECTION_ID,
|
||||
@@ -79,8 +79,8 @@ internal class ContentRootEntityImpl(private val dataSource: ContentRootEntityDa
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ContentRootEntityData?) : ModifiableWorkspaceEntityBase<ContentRootEntity, ContentRootEntityData>(result),
|
||||
ContentRootEntity.Builder {
|
||||
internal class Builder(result: ContentRootEntityData?) : ModifiableWorkspaceEntityBase<ContentRootEntity, ContentRootEntityData>(
|
||||
result), ContentRootEntity.Builder {
|
||||
internal constructor() : this(ContentRootEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -262,8 +262,8 @@ internal class ContentRootEntityImpl(private val dataSource: ContentRootEntityDa
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(SOURCEROOTS_CONNECTION_ID, this)!!
|
||||
.toList() as List<SourceRootEntity.Builder>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(SOURCEROOTS_CONNECTION_ID,
|
||||
this)!!.toList() as List<SourceRootEntity.Builder>) +
|
||||
(this.entityLinks[EntityLink(true, SOURCEROOTS_CONNECTION_ID)] as? List<SourceRootEntity.Builder> ?: emptyList())
|
||||
}
|
||||
else {
|
||||
@@ -309,8 +309,8 @@ internal class ContentRootEntityImpl(private val dataSource: ContentRootEntityDa
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(EXCLUDEDURLS_CONNECTION_ID, this)!!
|
||||
.toList() as List<ExcludeUrlEntity.Builder>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(EXCLUDEDURLS_CONNECTION_ID,
|
||||
this)!!.toList() as List<ExcludeUrlEntity.Builder>) +
|
||||
(this.entityLinks[EntityLink(true, EXCLUDEDURLS_CONNECTION_ID)] as? List<ExcludeUrlEntity.Builder> ?: emptyList())
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -33,13 +33,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class CustomSourceRootPropertiesEntityImpl(private val dataSource: CustomSourceRootPropertiesEntityData) :
|
||||
CustomSourceRootPropertiesEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class CustomSourceRootPropertiesEntityImpl(private val dataSource: CustomSourceRootPropertiesEntityData) : CustomSourceRootPropertiesEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val SOURCEROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
SourceRootEntity::class.java, CustomSourceRootPropertiesEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false
|
||||
)
|
||||
internal val SOURCEROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(SourceRootEntity::class.java,
|
||||
CustomSourceRootPropertiesEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
SOURCEROOT_CONNECTION_ID,
|
||||
@@ -67,9 +67,8 @@ internal class CustomSourceRootPropertiesEntityImpl(private val dataSource: Cust
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: CustomSourceRootPropertiesEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<CustomSourceRootPropertiesEntity, CustomSourceRootPropertiesEntityData>(result),
|
||||
CustomSourceRootPropertiesEntity.Builder {
|
||||
internal class Builder(result: CustomSourceRootPropertiesEntityData?) : ModifiableWorkspaceEntityBase<CustomSourceRootPropertiesEntity, CustomSourceRootPropertiesEntityData>(
|
||||
result), CustomSourceRootPropertiesEntity.Builder {
|
||||
internal constructor() : this(CustomSourceRootPropertiesEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -211,8 +210,7 @@ internal class CustomSourceRootPropertiesEntityData : WorkspaceEntityData<Custom
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.platform.workspace.jps.entities.CustomSourceRootPropertiesEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.platform.workspace.jps.entities.CustomSourceRootPropertiesEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
|
||||
@@ -49,8 +49,8 @@ internal class ExcludeUrlEntityImpl(private val dataSource: ExcludeUrlEntityData
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ExcludeUrlEntityData?) : ModifiableWorkspaceEntityBase<ExcludeUrlEntity, ExcludeUrlEntityData>(result),
|
||||
ExcludeUrlEntity.Builder {
|
||||
internal class Builder(result: ExcludeUrlEntityData?) : ModifiableWorkspaceEntityBase<ExcludeUrlEntity, ExcludeUrlEntityData>(
|
||||
result), ExcludeUrlEntity.Builder {
|
||||
internal constructor() : this(ExcludeUrlEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -34,12 +34,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ExcludeUrlOrderEntityImpl(private val dataSource: ExcludeUrlOrderEntityData) : ExcludeUrlOrderEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class ExcludeUrlOrderEntityImpl(private val dataSource: ExcludeUrlOrderEntityData) : ExcludeUrlOrderEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val CONTENTROOT_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ContentRootEntity::class.java, ExcludeUrlOrderEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val CONTENTROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(ContentRootEntity::class.java,
|
||||
ExcludeUrlOrderEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
CONTENTROOT_CONNECTION_ID,
|
||||
@@ -67,8 +68,8 @@ internal class ExcludeUrlOrderEntityImpl(private val dataSource: ExcludeUrlOrder
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ExcludeUrlOrderEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ExcludeUrlOrderEntity, ExcludeUrlOrderEntityData>(result), ExcludeUrlOrderEntity.Builder {
|
||||
internal class Builder(result: ExcludeUrlOrderEntityData?) : ModifiableWorkspaceEntityBase<ExcludeUrlOrderEntity, ExcludeUrlOrderEntityData>(
|
||||
result), ExcludeUrlOrderEntity.Builder {
|
||||
internal constructor() : this(ExcludeUrlOrderEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -32,13 +32,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ExternalSystemModuleOptionsEntityImpl(private val dataSource: ExternalSystemModuleOptionsEntityData) :
|
||||
ExternalSystemModuleOptionsEntity, WorkspaceEntityBase(dataSource) {
|
||||
internal class ExternalSystemModuleOptionsEntityImpl(private val dataSource: ExternalSystemModuleOptionsEntityData) : ExternalSystemModuleOptionsEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ModuleEntity::class.java, ExternalSystemModuleOptionsEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false
|
||||
)
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java,
|
||||
ExternalSystemModuleOptionsEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULE_CONNECTION_ID,
|
||||
@@ -102,9 +102,8 @@ internal class ExternalSystemModuleOptionsEntityImpl(private val dataSource: Ext
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ExternalSystemModuleOptionsEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ExternalSystemModuleOptionsEntity, ExternalSystemModuleOptionsEntityData>(result),
|
||||
ExternalSystemModuleOptionsEntity.Builder {
|
||||
internal class Builder(result: ExternalSystemModuleOptionsEntityData?) : ModifiableWorkspaceEntityBase<ExternalSystemModuleOptionsEntity, ExternalSystemModuleOptionsEntityData>(
|
||||
result), ExternalSystemModuleOptionsEntity.Builder {
|
||||
internal constructor() : this(ExternalSystemModuleOptionsEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -156,15 +155,12 @@ internal class ExternalSystemModuleOptionsEntityImpl(private val dataSource: Ext
|
||||
dataSource as ExternalSystemModuleOptionsEntity
|
||||
if (this.entitySource != dataSource.entitySource) this.entitySource = dataSource.entitySource
|
||||
if (this.externalSystem != dataSource?.externalSystem) this.externalSystem = dataSource.externalSystem
|
||||
if (this.externalSystemModuleVersion != dataSource?.externalSystemModuleVersion) this.externalSystemModuleVersion =
|
||||
dataSource.externalSystemModuleVersion
|
||||
if (this.externalSystemModuleVersion != dataSource?.externalSystemModuleVersion) this.externalSystemModuleVersion = dataSource.externalSystemModuleVersion
|
||||
if (this.linkedProjectPath != dataSource?.linkedProjectPath) this.linkedProjectPath = dataSource.linkedProjectPath
|
||||
if (this.linkedProjectId != dataSource?.linkedProjectId) this.linkedProjectId = dataSource.linkedProjectId
|
||||
if (this.rootProjectPath != dataSource?.rootProjectPath) this.rootProjectPath = dataSource.rootProjectPath
|
||||
if (this.externalSystemModuleGroup != dataSource?.externalSystemModuleGroup) this.externalSystemModuleGroup =
|
||||
dataSource.externalSystemModuleGroup
|
||||
if (this.externalSystemModuleType != dataSource?.externalSystemModuleType) this.externalSystemModuleType =
|
||||
dataSource.externalSystemModuleType
|
||||
if (this.externalSystemModuleGroup != dataSource?.externalSystemModuleGroup) this.externalSystemModuleGroup = dataSource.externalSystemModuleGroup
|
||||
if (this.externalSystemModuleType != dataSource?.externalSystemModuleType) this.externalSystemModuleType = dataSource.externalSystemModuleType
|
||||
updateChildToParentReferences(parents)
|
||||
}
|
||||
|
||||
@@ -305,8 +301,7 @@ internal class ExternalSystemModuleOptionsEntityData : WorkspaceEntityData<Exter
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.platform.workspace.jps.entities.ExternalSystemModuleOptionsEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.platform.workspace.jps.entities.ExternalSystemModuleOptionsEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
|
||||
@@ -36,10 +36,10 @@ import org.jetbrains.annotations.NonNls
|
||||
internal class FacetEntityImpl(private val dataSource: FacetEntityData) : FacetEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, FacetEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val UNDERLYINGFACET_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(FacetEntity::class.java, FacetEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, true)
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, FacetEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val UNDERLYINGFACET_CONNECTION_ID: ConnectionId = ConnectionId.create(FacetEntity::class.java, FacetEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULE_CONNECTION_ID,
|
||||
@@ -91,8 +91,8 @@ internal class FacetEntityImpl(private val dataSource: FacetEntityData) : FacetE
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: FacetEntityData?) : ModifiableWorkspaceEntityBase<FacetEntity, FacetEntityData>(result),
|
||||
FacetEntity.Builder {
|
||||
internal class Builder(result: FacetEntityData?) : ModifiableWorkspaceEntityBase<FacetEntity, FacetEntityData>(
|
||||
result), FacetEntity.Builder {
|
||||
internal constructor() : this(FacetEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -34,8 +34,8 @@ import org.jetbrains.annotations.ApiStatus.Internal
|
||||
internal class FacetsOrderEntityImpl(private val dataSource: FacetsOrderEntityData) : FacetsOrderEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULEENTITY_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, FacetsOrderEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val MODULEENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, FacetsOrderEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULEENTITY_CONNECTION_ID,
|
||||
@@ -63,8 +63,8 @@ internal class FacetsOrderEntityImpl(private val dataSource: FacetsOrderEntityDa
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: FacetsOrderEntityData?) : ModifiableWorkspaceEntityBase<FacetsOrderEntity, FacetsOrderEntityData>(result),
|
||||
FacetsOrderEntity.Builder {
|
||||
internal class Builder(result: FacetsOrderEntityData?) : ModifiableWorkspaceEntityBase<FacetsOrderEntity, FacetsOrderEntityData>(
|
||||
result), FacetsOrderEntity.Builder {
|
||||
internal constructor() : this(FacetsOrderEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -45,8 +45,8 @@ import org.jetbrains.annotations.NonNls
|
||||
internal class LibraryEntityImpl(private val dataSource: LibraryEntityData) : LibraryEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val EXCLUDEDROOTS_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(LibraryEntity::class.java, ExcludeUrlEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, true)
|
||||
internal val EXCLUDEDROOTS_CONNECTION_ID: ConnectionId = ConnectionId.create(LibraryEntity::class.java, ExcludeUrlEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, true)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
EXCLUDEDROOTS_CONNECTION_ID,
|
||||
@@ -94,8 +94,8 @@ internal class LibraryEntityImpl(private val dataSource: LibraryEntityData) : Li
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: LibraryEntityData?) : ModifiableWorkspaceEntityBase<LibraryEntity, LibraryEntityData>(result),
|
||||
LibraryEntity.Builder {
|
||||
internal class Builder(result: LibraryEntityData?) : ModifiableWorkspaceEntityBase<LibraryEntity, LibraryEntityData>(
|
||||
result), LibraryEntity.Builder {
|
||||
internal constructor() : this(LibraryEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -254,8 +254,8 @@ internal class LibraryEntityImpl(private val dataSource: LibraryEntityData) : Li
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(EXCLUDEDROOTS_CONNECTION_ID, this)!!
|
||||
.toList() as List<ExcludeUrlEntity.Builder>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(EXCLUDEDROOTS_CONNECTION_ID,
|
||||
this)!!.toList() as List<ExcludeUrlEntity.Builder>) +
|
||||
(this.entityLinks[EntityLink(true, EXCLUDEDROOTS_CONNECTION_ID)] as? List<ExcludeUrlEntity.Builder> ?: emptyList())
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -29,12 +29,12 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class LibraryPropertiesEntityImpl(private val dataSource: LibraryPropertiesEntityData) : LibraryPropertiesEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class LibraryPropertiesEntityImpl(private val dataSource: LibraryPropertiesEntityData) : LibraryPropertiesEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val LIBRARY_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(LibraryEntity::class.java, LibraryPropertiesEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val LIBRARY_CONNECTION_ID: ConnectionId = ConnectionId.create(LibraryEntity::class.java, LibraryPropertiesEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
LIBRARY_CONNECTION_ID,
|
||||
@@ -62,8 +62,8 @@ internal class LibraryPropertiesEntityImpl(private val dataSource: LibraryProper
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: LibraryPropertiesEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<LibraryPropertiesEntity, LibraryPropertiesEntityData>(result), LibraryPropertiesEntity.Builder {
|
||||
internal class Builder(result: LibraryPropertiesEntityData?) : ModifiableWorkspaceEntityBase<LibraryPropertiesEntity, LibraryPropertiesEntityData>(
|
||||
result), LibraryPropertiesEntity.Builder {
|
||||
internal constructor() : this(LibraryPropertiesEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -201,8 +201,7 @@ internal class LibraryPropertiesEntityData : WorkspaceEntityData<LibraryProperti
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.platform.workspace.jps.entities.LibraryPropertiesEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.platform.workspace.jps.entities.LibraryPropertiesEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
|
||||
@@ -5,4 +5,4 @@ import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
import com.intellij.platform.workspace.storage.metadata.MetadataStorageBridge
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBridge(MetadataStorageImpl)
|
||||
internal object MetadataStorageImpl : MetadataStorageBridge(MetadataStorageImpl)
|
||||
|
||||
@@ -32,12 +32,12 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ModuleCustomImlDataEntityImpl(private val dataSource: ModuleCustomImlDataEntityData) : ModuleCustomImlDataEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class ModuleCustomImlDataEntityImpl(private val dataSource: ModuleCustomImlDataEntityData) : ModuleCustomImlDataEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, ModuleCustomImlDataEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, ModuleCustomImlDataEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULE_CONNECTION_ID,
|
||||
@@ -70,8 +70,8 @@ internal class ModuleCustomImlDataEntityImpl(private val dataSource: ModuleCusto
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ModuleCustomImlDataEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ModuleCustomImlDataEntity, ModuleCustomImlDataEntityData>(result), ModuleCustomImlDataEntity.Builder {
|
||||
internal class Builder(result: ModuleCustomImlDataEntityData?) : ModifiableWorkspaceEntityBase<ModuleCustomImlDataEntity, ModuleCustomImlDataEntityData>(
|
||||
result), ModuleCustomImlDataEntity.Builder {
|
||||
internal constructor() : this(ModuleCustomImlDataEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -125,10 +125,8 @@ internal class ModuleCustomImlDataEntityImpl(private val dataSource: ModuleCusto
|
||||
override fun relabel(dataSource: WorkspaceEntity, parents: Set<WorkspaceEntity>?) {
|
||||
dataSource as ModuleCustomImlDataEntity
|
||||
if (this.entitySource != dataSource.entitySource) this.entitySource = dataSource.entitySource
|
||||
if (this.rootManagerTagCustomData != dataSource?.rootManagerTagCustomData) this.rootManagerTagCustomData =
|
||||
dataSource.rootManagerTagCustomData
|
||||
if (this.customModuleOptions != dataSource.customModuleOptions) this.customModuleOptions =
|
||||
dataSource.customModuleOptions.toMutableMap()
|
||||
if (this.rootManagerTagCustomData != dataSource?.rootManagerTagCustomData) this.rootManagerTagCustomData = dataSource.rootManagerTagCustomData
|
||||
if (this.customModuleOptions != dataSource.customModuleOptions) this.customModuleOptions = dataSource.customModuleOptions.toMutableMap()
|
||||
updateChildToParentReferences(parents)
|
||||
}
|
||||
|
||||
@@ -225,8 +223,7 @@ internal class ModuleCustomImlDataEntityData : WorkspaceEntityData<ModuleCustomI
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.platform.workspace.jps.entities.ModuleCustomImlDataEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.platform.workspace.jps.entities.ModuleCustomImlDataEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
|
||||
@@ -41,10 +41,10 @@ import org.jetbrains.annotations.NonNls
|
||||
internal class ModuleEntityImpl(private val dataSource: ModuleEntityData) : ModuleEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val CONTENTROOTS_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, ContentRootEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val FACETS_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, FacetEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val CONTENTROOTS_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, ContentRootEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val FACETS_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, FacetEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
CONTENTROOTS_CONNECTION_ID,
|
||||
@@ -90,8 +90,8 @@ internal class ModuleEntityImpl(private val dataSource: ModuleEntityData) : Modu
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ModuleEntityData?) : ModifiableWorkspaceEntityBase<ModuleEntity, ModuleEntityData>(result),
|
||||
ModuleEntity.Builder {
|
||||
internal class Builder(result: ModuleEntityData?) : ModifiableWorkspaceEntityBase<ModuleEntity, ModuleEntityData>(
|
||||
result), ModuleEntity.Builder {
|
||||
internal constructor() : this(ModuleEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -230,8 +230,8 @@ internal class ModuleEntityImpl(private val dataSource: ModuleEntityData) : Modu
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CONTENTROOTS_CONNECTION_ID, this)!!
|
||||
.toList() as List<ContentRootEntity.Builder>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CONTENTROOTS_CONNECTION_ID,
|
||||
this)!!.toList() as List<ContentRootEntity.Builder>) +
|
||||
(this.entityLinks[EntityLink(true, CONTENTROOTS_CONNECTION_ID)] as? List<ContentRootEntity.Builder> ?: emptyList())
|
||||
}
|
||||
else {
|
||||
@@ -277,8 +277,8 @@ internal class ModuleEntityImpl(private val dataSource: ModuleEntityData) : Modu
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(FACETS_CONNECTION_ID, this)!!
|
||||
.toList() as List<FacetEntity.Builder>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(FACETS_CONNECTION_ID,
|
||||
this)!!.toList() as List<FacetEntity.Builder>) +
|
||||
(this.entityLinks[EntityLink(true, FACETS_CONNECTION_ID)] as? List<FacetEntity.Builder> ?: emptyList())
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -33,12 +33,12 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ModuleGroupPathEntityImpl(private val dataSource: ModuleGroupPathEntityData) : ModuleGroupPathEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class ModuleGroupPathEntityImpl(private val dataSource: ModuleGroupPathEntityData) : ModuleGroupPathEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, ModuleGroupPathEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, ModuleGroupPathEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULE_CONNECTION_ID,
|
||||
@@ -66,8 +66,8 @@ internal class ModuleGroupPathEntityImpl(private val dataSource: ModuleGroupPath
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ModuleGroupPathEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ModuleGroupPathEntity, ModuleGroupPathEntityData>(result), ModuleGroupPathEntity.Builder {
|
||||
internal class Builder(result: ModuleGroupPathEntityData?) : ModifiableWorkspaceEntityBase<ModuleGroupPathEntity, ModuleGroupPathEntityData>(
|
||||
result), ModuleGroupPathEntity.Builder {
|
||||
internal constructor() : this(ModuleGroupPathEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -28,8 +28,8 @@ import org.jetbrains.annotations.NonNls
|
||||
internal class SourceRootEntityImpl(private val dataSource: SourceRootEntityData) : SourceRootEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val CONTENTROOT_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ContentRootEntity::class.java, SourceRootEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
internal val CONTENTROOT_CONNECTION_ID: ConnectionId = ConnectionId.create(ContentRootEntity::class.java, SourceRootEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
CONTENTROOT_CONNECTION_ID,
|
||||
@@ -63,8 +63,8 @@ internal class SourceRootEntityImpl(private val dataSource: SourceRootEntityData
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: SourceRootEntityData?) : ModifiableWorkspaceEntityBase<SourceRootEntity, SourceRootEntityData>(result),
|
||||
SourceRootEntity.Builder {
|
||||
internal class Builder(result: SourceRootEntityData?) : ModifiableWorkspaceEntityBase<SourceRootEntity, SourceRootEntityData>(
|
||||
result), SourceRootEntity.Builder {
|
||||
internal constructor() : this(SourceRootEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -34,12 +34,13 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class SourceRootOrderEntityImpl(private val dataSource: SourceRootOrderEntityData) : SourceRootOrderEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class SourceRootOrderEntityImpl(private val dataSource: SourceRootOrderEntityData) : SourceRootOrderEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val CONTENTROOTENTITY_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ContentRootEntity::class.java, SourceRootOrderEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val CONTENTROOTENTITY_CONNECTION_ID: ConnectionId = ConnectionId.create(ContentRootEntity::class.java,
|
||||
SourceRootOrderEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
CONTENTROOTENTITY_CONNECTION_ID,
|
||||
@@ -67,8 +68,8 @@ internal class SourceRootOrderEntityImpl(private val dataSource: SourceRootOrder
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: SourceRootOrderEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<SourceRootOrderEntity, SourceRootOrderEntityData>(result), SourceRootOrderEntity.Builder {
|
||||
internal class Builder(result: SourceRootOrderEntityData?) : ModifiableWorkspaceEntityBase<SourceRootOrderEntity, SourceRootOrderEntityData>(
|
||||
result), SourceRootOrderEntity.Builder {
|
||||
internal constructor() : this(SourceRootOrderEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -172,9 +173,8 @@ internal class SourceRootOrderEntityImpl(private val dataSource: SourceRootOrder
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
CONTENTROOTENTITY_CONNECTION_ID, this
|
||||
) as? ContentRootEntity.Builder)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(CONTENTROOTENTITY_CONNECTION_ID,
|
||||
this) as? ContentRootEntity.Builder)
|
||||
?: (this.entityLinks[EntityLink(false, CONTENTROOTENTITY_CONNECTION_ID)]!! as ContentRootEntity.Builder)
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -36,12 +36,12 @@ import org.jetbrains.annotations.NonNls
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class TestModulePropertiesEntityImpl(private val dataSource: TestModulePropertiesEntityData) : TestModulePropertiesEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class TestModulePropertiesEntityImpl(private val dataSource: TestModulePropertiesEntityData) : TestModulePropertiesEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(ModuleEntity::class.java, TestModulePropertiesEntity::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val MODULE_CONNECTION_ID: ConnectionId = ConnectionId.create(ModuleEntity::class.java, TestModulePropertiesEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
MODULE_CONNECTION_ID,
|
||||
@@ -69,8 +69,8 @@ internal class TestModulePropertiesEntityImpl(private val dataSource: TestModule
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: TestModulePropertiesEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<TestModulePropertiesEntity, TestModulePropertiesEntityData>(result), TestModulePropertiesEntity.Builder {
|
||||
internal class Builder(result: TestModulePropertiesEntityData?) : ModifiableWorkspaceEntityBase<TestModulePropertiesEntity, TestModulePropertiesEntityData>(
|
||||
result), TestModulePropertiesEntity.Builder {
|
||||
internal constructor() : this(TestModulePropertiesEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -250,8 +250,7 @@ internal class TestModulePropertiesEntityData : WorkspaceEntityData<TestModulePr
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn(
|
||||
"com.intellij.platform.workspace.jps.entities.TestModulePropertiesEntity"
|
||||
) as EntityMetadata
|
||||
"com.intellij.platform.workspace.jps.entities.TestModulePropertiesEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
|
||||
@@ -5,4 +5,4 @@ import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
import com.intellij.platform.workspace.storage.metadata.MetadataStorageBridge
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBridge(MetadataStorageImpl)
|
||||
internal object MetadataStorageImpl : MetadataStorageBridge(MetadataStorageImpl)
|
||||
|
||||
@@ -47,9 +47,7 @@ interface JavaProjectSettingsEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyJavaProjectSettingsEntity(
|
||||
entity: JavaProjectSettingsEntity,
|
||||
modification: JavaProjectSettingsEntity.Builder.() -> Unit,
|
||||
): JavaProjectSettingsEntity {
|
||||
return modifyEntity(JavaProjectSettingsEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): JavaProjectSettingsEntity = modifyEntity(JavaProjectSettingsEntity.Builder::class.java, entity, modification)
|
||||
|
||||
var ProjectSettingsEntity.Builder.javaProjectSettings: JavaProjectSettingsEntity.Builder?
|
||||
by WorkspaceEntity.extensionBuilder(JavaProjectSettingsEntity::class.java)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.java.workspace.entities
|
||||
|
||||
import com.intellij.openapi.util.NlsSafe
|
||||
@@ -73,9 +73,7 @@ interface ArtifactEntity : WorkspaceEntityWithSymbolicId {
|
||||
fun MutableEntityStorage.modifyArtifactEntity(
|
||||
entity: ArtifactEntity,
|
||||
modification: ArtifactEntity.Builder.() -> Unit,
|
||||
): ArtifactEntity {
|
||||
return modifyEntity(ArtifactEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ArtifactEntity = modifyEntity(ArtifactEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ArtifactPropertiesEntity : WorkspaceEntity {
|
||||
@@ -118,9 +116,7 @@ interface ArtifactPropertiesEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyArtifactPropertiesEntity(
|
||||
entity: ArtifactPropertiesEntity,
|
||||
modification: ArtifactPropertiesEntity.Builder.() -> Unit,
|
||||
): ArtifactPropertiesEntity {
|
||||
return modifyEntity(ArtifactPropertiesEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ArtifactPropertiesEntity = modifyEntity(ArtifactPropertiesEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@Abstract interface PackagingElementEntity : WorkspaceEntity {
|
||||
@@ -190,8 +186,7 @@ interface DirectoryPackagingElementEntity: CompositePackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<DirectoryPackagingElementEntity>,
|
||||
CompositePackagingElementEntity.Builder<DirectoryPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<DirectoryPackagingElementEntity>, CompositePackagingElementEntity.Builder<DirectoryPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
override var artifact: ArtifactEntity.Builder?
|
||||
@@ -223,9 +218,7 @@ interface DirectoryPackagingElementEntity: CompositePackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyDirectoryPackagingElementEntity(
|
||||
entity: DirectoryPackagingElementEntity,
|
||||
modification: DirectoryPackagingElementEntity.Builder.() -> Unit,
|
||||
): DirectoryPackagingElementEntity {
|
||||
return modifyEntity(DirectoryPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): DirectoryPackagingElementEntity = modifyEntity(DirectoryPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ArchivePackagingElementEntity: CompositePackagingElementEntity {
|
||||
@@ -233,8 +226,7 @@ interface ArchivePackagingElementEntity: CompositePackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<ArchivePackagingElementEntity>,
|
||||
CompositePackagingElementEntity.Builder<ArchivePackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<ArchivePackagingElementEntity>, CompositePackagingElementEntity.Builder<ArchivePackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
override var artifact: ArtifactEntity.Builder?
|
||||
@@ -266,16 +258,13 @@ interface ArchivePackagingElementEntity: CompositePackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyArchivePackagingElementEntity(
|
||||
entity: ArchivePackagingElementEntity,
|
||||
modification: ArchivePackagingElementEntity.Builder.() -> Unit,
|
||||
): ArchivePackagingElementEntity {
|
||||
return modifyEntity(ArchivePackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ArchivePackagingElementEntity = modifyEntity(ArchivePackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ArtifactRootElementEntity: CompositePackagingElementEntity {
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<ArtifactRootElementEntity>,
|
||||
CompositePackagingElementEntity.Builder<ArtifactRootElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<ArtifactRootElementEntity>, CompositePackagingElementEntity.Builder<ArtifactRootElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
override var artifact: ArtifactEntity.Builder?
|
||||
@@ -304,9 +293,7 @@ interface ArtifactRootElementEntity: CompositePackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyArtifactRootElementEntity(
|
||||
entity: ArtifactRootElementEntity,
|
||||
modification: ArtifactRootElementEntity.Builder.() -> Unit,
|
||||
): ArtifactRootElementEntity {
|
||||
return modifyEntity(ArtifactRootElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ArtifactRootElementEntity = modifyEntity(ArtifactRootElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ArtifactOutputPackagingElementEntity: PackagingElementEntity {
|
||||
@@ -314,8 +301,7 @@ interface ArtifactOutputPackagingElementEntity: PackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<ArtifactOutputPackagingElementEntity>,
|
||||
PackagingElementEntity.Builder<ArtifactOutputPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<ArtifactOutputPackagingElementEntity>, PackagingElementEntity.Builder<ArtifactOutputPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
var artifact: ArtifactId?
|
||||
@@ -343,9 +329,7 @@ interface ArtifactOutputPackagingElementEntity: PackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyArtifactOutputPackagingElementEntity(
|
||||
entity: ArtifactOutputPackagingElementEntity,
|
||||
modification: ArtifactOutputPackagingElementEntity.Builder.() -> Unit,
|
||||
): ArtifactOutputPackagingElementEntity {
|
||||
return modifyEntity(ArtifactOutputPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ArtifactOutputPackagingElementEntity = modifyEntity(ArtifactOutputPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
|
||||
@Parent
|
||||
var ArtifactOutputPackagingElementEntity.Builder.artifactEntity: ArtifactEntity.Builder?
|
||||
@@ -361,8 +345,7 @@ interface ModuleOutputPackagingElementEntity : PackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<ModuleOutputPackagingElementEntity>,
|
||||
PackagingElementEntity.Builder<ModuleOutputPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<ModuleOutputPackagingElementEntity>, PackagingElementEntity.Builder<ModuleOutputPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
var module: ModuleId?
|
||||
@@ -390,9 +373,7 @@ interface ModuleOutputPackagingElementEntity : PackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyModuleOutputPackagingElementEntity(
|
||||
entity: ModuleOutputPackagingElementEntity,
|
||||
modification: ModuleOutputPackagingElementEntity.Builder.() -> Unit,
|
||||
): ModuleOutputPackagingElementEntity {
|
||||
return modifyEntity(ModuleOutputPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ModuleOutputPackagingElementEntity = modifyEntity(ModuleOutputPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface LibraryFilesPackagingElementEntity : PackagingElementEntity {
|
||||
@@ -400,8 +381,7 @@ interface LibraryFilesPackagingElementEntity : PackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<LibraryFilesPackagingElementEntity>,
|
||||
PackagingElementEntity.Builder<LibraryFilesPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<LibraryFilesPackagingElementEntity>, PackagingElementEntity.Builder<LibraryFilesPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
var library: LibraryId?
|
||||
@@ -429,9 +409,7 @@ interface LibraryFilesPackagingElementEntity : PackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyLibraryFilesPackagingElementEntity(
|
||||
entity: LibraryFilesPackagingElementEntity,
|
||||
modification: LibraryFilesPackagingElementEntity.Builder.() -> Unit,
|
||||
): LibraryFilesPackagingElementEntity {
|
||||
return modifyEntity(LibraryFilesPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): LibraryFilesPackagingElementEntity = modifyEntity(LibraryFilesPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ModuleSourcePackagingElementEntity : PackagingElementEntity {
|
||||
@@ -439,8 +417,7 @@ interface ModuleSourcePackagingElementEntity : PackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<ModuleSourcePackagingElementEntity>,
|
||||
PackagingElementEntity.Builder<ModuleSourcePackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<ModuleSourcePackagingElementEntity>, PackagingElementEntity.Builder<ModuleSourcePackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
var module: ModuleId?
|
||||
@@ -468,9 +445,7 @@ interface ModuleSourcePackagingElementEntity : PackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyModuleSourcePackagingElementEntity(
|
||||
entity: ModuleSourcePackagingElementEntity,
|
||||
modification: ModuleSourcePackagingElementEntity.Builder.() -> Unit,
|
||||
): ModuleSourcePackagingElementEntity {
|
||||
return modifyEntity(ModuleSourcePackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ModuleSourcePackagingElementEntity = modifyEntity(ModuleSourcePackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ModuleTestOutputPackagingElementEntity : PackagingElementEntity {
|
||||
@@ -478,8 +453,7 @@ interface ModuleTestOutputPackagingElementEntity : PackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<ModuleTestOutputPackagingElementEntity>,
|
||||
PackagingElementEntity.Builder<ModuleTestOutputPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<ModuleTestOutputPackagingElementEntity>, PackagingElementEntity.Builder<ModuleTestOutputPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
var module: ModuleId?
|
||||
@@ -507,9 +481,7 @@ interface ModuleTestOutputPackagingElementEntity : PackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyModuleTestOutputPackagingElementEntity(
|
||||
entity: ModuleTestOutputPackagingElementEntity,
|
||||
modification: ModuleTestOutputPackagingElementEntity.Builder.() -> Unit,
|
||||
): ModuleTestOutputPackagingElementEntity {
|
||||
return modifyEntity(ModuleTestOutputPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ModuleTestOutputPackagingElementEntity = modifyEntity(ModuleTestOutputPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@Abstract interface FileOrDirectoryPackagingElementEntity : PackagingElementEntity {
|
||||
@@ -523,8 +495,8 @@ fun MutableEntityStorage.modifyModuleTestOutputPackagingElementEntity(
|
||||
var filePath: VirtualFileUrl
|
||||
}
|
||||
|
||||
companion object :
|
||||
EntityType<FileOrDirectoryPackagingElementEntity, Builder<FileOrDirectoryPackagingElementEntity>>(PackagingElementEntity) {
|
||||
companion object : EntityType<FileOrDirectoryPackagingElementEntity, Builder<FileOrDirectoryPackagingElementEntity>>(
|
||||
PackagingElementEntity) {
|
||||
@JvmOverloads
|
||||
@JvmStatic
|
||||
@JvmName("create")
|
||||
@@ -547,8 +519,7 @@ fun MutableEntityStorage.modifyModuleTestOutputPackagingElementEntity(
|
||||
interface DirectoryCopyPackagingElementEntity : FileOrDirectoryPackagingElementEntity {
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<DirectoryCopyPackagingElementEntity>,
|
||||
FileOrDirectoryPackagingElementEntity.Builder<DirectoryCopyPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<DirectoryCopyPackagingElementEntity>, FileOrDirectoryPackagingElementEntity.Builder<DirectoryCopyPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
override var filePath: VirtualFileUrl
|
||||
@@ -578,9 +549,7 @@ interface DirectoryCopyPackagingElementEntity : FileOrDirectoryPackagingElementE
|
||||
fun MutableEntityStorage.modifyDirectoryCopyPackagingElementEntity(
|
||||
entity: DirectoryCopyPackagingElementEntity,
|
||||
modification: DirectoryCopyPackagingElementEntity.Builder.() -> Unit,
|
||||
): DirectoryCopyPackagingElementEntity {
|
||||
return modifyEntity(DirectoryCopyPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): DirectoryCopyPackagingElementEntity = modifyEntity(DirectoryCopyPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface ExtractedDirectoryPackagingElementEntity: FileOrDirectoryPackagingElementEntity {
|
||||
@@ -588,8 +557,7 @@ interface ExtractedDirectoryPackagingElementEntity: FileOrDirectoryPackagingElem
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<ExtractedDirectoryPackagingElementEntity>,
|
||||
FileOrDirectoryPackagingElementEntity.Builder<ExtractedDirectoryPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<ExtractedDirectoryPackagingElementEntity>, FileOrDirectoryPackagingElementEntity.Builder<ExtractedDirectoryPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
override var filePath: VirtualFileUrl
|
||||
@@ -622,9 +590,8 @@ interface ExtractedDirectoryPackagingElementEntity: FileOrDirectoryPackagingElem
|
||||
fun MutableEntityStorage.modifyExtractedDirectoryPackagingElementEntity(
|
||||
entity: ExtractedDirectoryPackagingElementEntity,
|
||||
modification: ExtractedDirectoryPackagingElementEntity.Builder.() -> Unit,
|
||||
): ExtractedDirectoryPackagingElementEntity {
|
||||
return modifyEntity(ExtractedDirectoryPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ExtractedDirectoryPackagingElementEntity =
|
||||
modifyEntity(ExtractedDirectoryPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface FileCopyPackagingElementEntity : FileOrDirectoryPackagingElementEntity {
|
||||
@@ -632,8 +599,7 @@ interface FileCopyPackagingElementEntity : FileOrDirectoryPackagingElementEntity
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<FileCopyPackagingElementEntity>,
|
||||
FileOrDirectoryPackagingElementEntity.Builder<FileCopyPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<FileCopyPackagingElementEntity>, FileOrDirectoryPackagingElementEntity.Builder<FileCopyPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
override var filePath: VirtualFileUrl
|
||||
@@ -664,9 +630,7 @@ interface FileCopyPackagingElementEntity : FileOrDirectoryPackagingElementEntity
|
||||
fun MutableEntityStorage.modifyFileCopyPackagingElementEntity(
|
||||
entity: FileCopyPackagingElementEntity,
|
||||
modification: FileCopyPackagingElementEntity.Builder.() -> Unit,
|
||||
): FileCopyPackagingElementEntity {
|
||||
return modifyEntity(FileCopyPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): FileCopyPackagingElementEntity = modifyEntity(FileCopyPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
interface CustomPackagingElementEntity : CompositePackagingElementEntity {
|
||||
@@ -675,8 +639,7 @@ interface CustomPackagingElementEntity : CompositePackagingElementEntity {
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<CustomPackagingElementEntity>,
|
||||
CompositePackagingElementEntity.Builder<CustomPackagingElementEntity> {
|
||||
interface Builder : WorkspaceEntity.Builder<CustomPackagingElementEntity>, CompositePackagingElementEntity.Builder<CustomPackagingElementEntity> {
|
||||
override var entitySource: EntitySource
|
||||
override var parentEntity: CompositePackagingElementEntity.Builder<out CompositePackagingElementEntity>?
|
||||
override var artifact: ArtifactEntity.Builder?
|
||||
@@ -711,9 +674,7 @@ interface CustomPackagingElementEntity : CompositePackagingElementEntity {
|
||||
fun MutableEntityStorage.modifyCustomPackagingElementEntity(
|
||||
entity: CustomPackagingElementEntity,
|
||||
modification: CustomPackagingElementEntity.Builder.() -> Unit,
|
||||
): CustomPackagingElementEntity {
|
||||
return modifyEntity(CustomPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): CustomPackagingElementEntity = modifyEntity(CustomPackagingElementEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
/**
|
||||
@@ -754,7 +715,5 @@ interface ArtifactsOrderEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyArtifactsOrderEntity(
|
||||
entity: ArtifactsOrderEntity,
|
||||
modification: ArtifactsOrderEntity.Builder.() -> Unit,
|
||||
): ArtifactsOrderEntity {
|
||||
return modifyEntity(ArtifactsOrderEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ArtifactsOrderEntity = modifyEntity(ArtifactsOrderEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.java.workspace.entities
|
||||
|
||||
import com.intellij.platform.workspace.jps.entities.ModuleEntity
|
||||
@@ -63,9 +63,7 @@ interface JavaModuleSettingsEntity: WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyJavaModuleSettingsEntity(
|
||||
entity: JavaModuleSettingsEntity,
|
||||
modification: JavaModuleSettingsEntity.Builder.() -> Unit,
|
||||
): JavaModuleSettingsEntity {
|
||||
return modifyEntity(JavaModuleSettingsEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): JavaModuleSettingsEntity = modifyEntity(JavaModuleSettingsEntity.Builder::class.java, entity, modification)
|
||||
|
||||
var ModuleEntity.Builder.javaSettings: JavaModuleSettingsEntity.Builder?
|
||||
by WorkspaceEntity.extensionBuilder(JavaModuleSettingsEntity::class.java)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.java.workspace.entities
|
||||
|
||||
import com.intellij.openapi.util.NlsSafe
|
||||
@@ -52,9 +52,7 @@ interface JavaSourceRootPropertiesEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyJavaSourceRootPropertiesEntity(
|
||||
entity: JavaSourceRootPropertiesEntity,
|
||||
modification: JavaSourceRootPropertiesEntity.Builder.() -> Unit,
|
||||
): JavaSourceRootPropertiesEntity {
|
||||
return modifyEntity(JavaSourceRootPropertiesEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): JavaSourceRootPropertiesEntity = modifyEntity(JavaSourceRootPropertiesEntity.Builder::class.java, entity, modification)
|
||||
|
||||
var SourceRootEntity.Builder.javaSourceRoots: List<JavaSourceRootPropertiesEntity.Builder>
|
||||
by WorkspaceEntity.extensionBuilder(JavaSourceRootPropertiesEntity::class.java)
|
||||
@@ -105,9 +103,7 @@ interface JavaResourceRootPropertiesEntity: WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyJavaResourceRootPropertiesEntity(
|
||||
entity: JavaResourceRootPropertiesEntity,
|
||||
modification: JavaResourceRootPropertiesEntity.Builder.() -> Unit,
|
||||
): JavaResourceRootPropertiesEntity {
|
||||
return modifyEntity(JavaResourceRootPropertiesEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): JavaResourceRootPropertiesEntity = modifyEntity(JavaResourceRootPropertiesEntity.Builder::class.java, entity, modification)
|
||||
|
||||
var SourceRootEntity.Builder.javaResourceRoots: List<JavaResourceRootPropertiesEntity.Builder>
|
||||
by WorkspaceEntity.extensionBuilder(JavaResourceRootPropertiesEntity::class.java)
|
||||
|
||||
@@ -39,7 +39,5 @@ interface ProjectSettingsEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyProjectSettingsEntity(
|
||||
entity: ProjectSettingsEntity,
|
||||
modification: ProjectSettingsEntity.Builder.() -> Unit,
|
||||
): ProjectSettingsEntity {
|
||||
return modifyEntity(ProjectSettingsEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ProjectSettingsEntity = modifyEntity(ProjectSettingsEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
|
||||
import com.intellij.openapi.util.NlsSafe
|
||||
@@ -70,9 +70,7 @@ interface LibraryEntity : WorkspaceEntityWithSymbolicId {
|
||||
fun MutableEntityStorage.modifyLibraryEntity(
|
||||
entity: LibraryEntity,
|
||||
modification: LibraryEntity.Builder.() -> Unit,
|
||||
): LibraryEntity {
|
||||
return modifyEntity(LibraryEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): LibraryEntity = modifyEntity(LibraryEntity.Builder::class.java, entity, modification)
|
||||
|
||||
@get:Internal
|
||||
@set:Internal
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
@@ -47,9 +47,7 @@ interface ExcludeUrlEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyExcludeUrlEntity(
|
||||
entity: ExcludeUrlEntity,
|
||||
modification: ExcludeUrlEntity.Builder.() -> Unit,
|
||||
): ExcludeUrlEntity {
|
||||
return modifyEntity(ExcludeUrlEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ExcludeUrlEntity = modifyEntity(ExcludeUrlEntity.Builder::class.java, entity, modification)
|
||||
|
||||
@Parent
|
||||
var ExcludeUrlEntity.Builder.contentRoot: ContentRootEntity.Builder?
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
@@ -60,6 +60,7 @@ interface FacetEntity : ModuleSettingsFacetBridgeEntity {
|
||||
return builder
|
||||
}
|
||||
|
||||
//region compatibility generated code
|
||||
@Deprecated(
|
||||
message = "This method is deprecated and will be removed in next major release",
|
||||
replaceWith = ReplaceWith("invoke(moduleId, name, typeId, entitySource, init)"),
|
||||
@@ -74,6 +75,7 @@ interface FacetEntity : ModuleSettingsFacetBridgeEntity {
|
||||
entitySource: EntitySource,
|
||||
init: (Builder.() -> Unit)? = null,
|
||||
): Builder = invoke(moduleId, name, typeId, entitySource, init)
|
||||
//endregion compatibility generated code
|
||||
}
|
||||
//endregion
|
||||
}
|
||||
@@ -82,9 +84,7 @@ interface FacetEntity : ModuleSettingsFacetBridgeEntity {
|
||||
fun MutableEntityStorage.modifyFacetEntity(
|
||||
entity: FacetEntity,
|
||||
modification: FacetEntity.Builder.() -> Unit,
|
||||
): FacetEntity {
|
||||
return modifyEntity(FacetEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): FacetEntity = modifyEntity(FacetEntity.Builder::class.java, entity, modification)
|
||||
|
||||
var FacetEntity.Builder.childrenFacets: List<FacetEntity.Builder>
|
||||
by WorkspaceEntity.extensionBuilder(FacetEntity::class.java)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
@@ -51,9 +51,7 @@ interface LibraryPropertiesEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyLibraryPropertiesEntity(
|
||||
entity: LibraryPropertiesEntity,
|
||||
modification: LibraryPropertiesEntity.Builder.() -> Unit,
|
||||
): LibraryPropertiesEntity {
|
||||
return modifyEntity(LibraryPropertiesEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): LibraryPropertiesEntity = modifyEntity(LibraryPropertiesEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
@file:JvmName("ModuleEntityAndExtensions")
|
||||
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
@@ -63,9 +63,7 @@ interface ModuleEntity : WorkspaceEntityWithSymbolicId {
|
||||
fun MutableEntityStorage.modifyModuleEntity(
|
||||
entity: ModuleEntity,
|
||||
modification: ModuleEntity.Builder.() -> Unit,
|
||||
): ModuleEntity {
|
||||
return modifyEntity(ModuleEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ModuleEntity = modifyEntity(ModuleEntity.Builder::class.java, entity, modification)
|
||||
|
||||
@get:Internal
|
||||
@set:Internal
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
@file:JvmName("ModuleExtensions")
|
||||
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
@@ -63,9 +63,7 @@ interface ModuleCustomImlDataEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyModuleCustomImlDataEntity(
|
||||
entity: ModuleCustomImlDataEntity,
|
||||
modification: ModuleCustomImlDataEntity.Builder.() -> Unit,
|
||||
): ModuleCustomImlDataEntity {
|
||||
return modifyEntity(ModuleCustomImlDataEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ModuleCustomImlDataEntity = modifyEntity(ModuleCustomImlDataEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
@@ -116,9 +114,7 @@ interface ModuleGroupPathEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyModuleGroupPathEntity(
|
||||
entity: ModuleGroupPathEntity,
|
||||
modification: ModuleGroupPathEntity.Builder.() -> Unit,
|
||||
): ModuleGroupPathEntity {
|
||||
return modifyEntity(ModuleGroupPathEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ModuleGroupPathEntity = modifyEntity(ModuleGroupPathEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
@@ -178,9 +174,7 @@ interface ExternalSystemModuleOptionsEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyExternalSystemModuleOptionsEntity(
|
||||
entity: ExternalSystemModuleOptionsEntity,
|
||||
modification: ExternalSystemModuleOptionsEntity.Builder.() -> Unit,
|
||||
): ExternalSystemModuleOptionsEntity {
|
||||
return modifyEntity(ExternalSystemModuleOptionsEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ExternalSystemModuleOptionsEntity = modifyEntity(ExternalSystemModuleOptionsEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
@@ -228,9 +222,7 @@ interface TestModulePropertiesEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyTestModulePropertiesEntity(
|
||||
entity: TestModulePropertiesEntity,
|
||||
modification: TestModulePropertiesEntity.Builder.() -> Unit,
|
||||
): TestModulePropertiesEntity {
|
||||
return modifyEntity(TestModulePropertiesEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): TestModulePropertiesEntity = modifyEntity(TestModulePropertiesEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
|
||||
import com.intellij.openapi.util.NlsSafe
|
||||
@@ -54,9 +54,7 @@ interface FacetsOrderEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyFacetsOrderEntity(
|
||||
entity: FacetsOrderEntity,
|
||||
modification: FacetsOrderEntity.Builder.() -> Unit,
|
||||
): FacetsOrderEntity {
|
||||
return modifyEntity(FacetsOrderEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): FacetsOrderEntity = modifyEntity(FacetsOrderEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
|
||||
import com.intellij.openapi.util.NlsSafe
|
||||
@@ -61,9 +61,7 @@ interface ContentRootEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyContentRootEntity(
|
||||
entity: ContentRootEntity,
|
||||
modification: ContentRootEntity.Builder.() -> Unit,
|
||||
): ContentRootEntity {
|
||||
return modifyEntity(ContentRootEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ContentRootEntity = modifyEntity(ContentRootEntity.Builder::class.java, entity, modification)
|
||||
|
||||
@get:Internal
|
||||
@set:Internal
|
||||
@@ -132,9 +130,7 @@ interface SourceRootEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifySourceRootEntity(
|
||||
entity: SourceRootEntity,
|
||||
modification: SourceRootEntity.Builder.() -> Unit,
|
||||
): SourceRootEntity {
|
||||
return modifyEntity(SourceRootEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): SourceRootEntity = modifyEntity(SourceRootEntity.Builder::class.java, entity, modification)
|
||||
|
||||
@get:Internal
|
||||
@set:Internal
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
@file:JvmName("RootsExtensions")
|
||||
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
@@ -58,9 +58,7 @@ interface SourceRootOrderEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifySourceRootOrderEntity(
|
||||
entity: SourceRootOrderEntity,
|
||||
modification: SourceRootOrderEntity.Builder.() -> Unit,
|
||||
): SourceRootOrderEntity {
|
||||
return modifyEntity(SourceRootOrderEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): SourceRootOrderEntity = modifyEntity(SourceRootOrderEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
@@ -111,9 +109,7 @@ interface CustomSourceRootPropertiesEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyCustomSourceRootPropertiesEntity(
|
||||
entity: CustomSourceRootPropertiesEntity,
|
||||
modification: CustomSourceRootPropertiesEntity.Builder.() -> Unit,
|
||||
): CustomSourceRootPropertiesEntity {
|
||||
return modifyEntity(CustomSourceRootPropertiesEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): CustomSourceRootPropertiesEntity = modifyEntity(CustomSourceRootPropertiesEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
@@ -163,9 +159,7 @@ interface ExcludeUrlOrderEntity : WorkspaceEntity {
|
||||
fun MutableEntityStorage.modifyExcludeUrlOrderEntity(
|
||||
entity: ExcludeUrlOrderEntity,
|
||||
modification: ExcludeUrlOrderEntity.Builder.() -> Unit,
|
||||
): ExcludeUrlOrderEntity {
|
||||
return modifyEntity(ExcludeUrlOrderEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): ExcludeUrlOrderEntity = modifyEntity(ExcludeUrlOrderEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
@get:Internal
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.jps.entities
|
||||
|
||||
import com.intellij.platform.workspace.storage.*
|
||||
@@ -59,9 +59,7 @@ interface SdkEntity : WorkspaceEntityWithSymbolicId {
|
||||
fun MutableEntityStorage.modifySdkEntity(
|
||||
entity: SdkEntity,
|
||||
modification: SdkEntity.Builder.() -> Unit,
|
||||
): SdkEntity {
|
||||
return modifyEntity(SdkEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
): SdkEntity = modifyEntity(SdkEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
|
||||
|
||||
|
||||
@@ -9,24 +9,24 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.Source", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.ProjectRootEntitySource", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")), withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
typeMetadata = FinalClassMetadata.ObjectMetadata(fqName = "com.intellij.workspaceModel.ide.Source", properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "virtualFileUrl",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = true,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.url.VirtualFileUrl")),
|
||||
withDefault = false)), supertypes = listOf("com.intellij.platform.workspace.storage.EntitySource"))
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 441826386)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.ProjectRootEntitySource", metadataHash = 544411415)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.Source", metadataHash = 1093972899)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = -1468425945)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.ide.Source", metadataHash = 1093972899)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.storage.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
@@ -9,26 +10,44 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.workspace.storage.WorkspaceEntity", entityDataFqName = "com.intellij.platform.workspace.storage.impl.WorkspaceEntityData", supertypes = listOf(), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false)), extProperties = listOf(), isAbstract = true)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.workspace.storage.WorkspaceEntity",
|
||||
entityDataFqName = "com.intellij.platform.workspace.storage.impl.WorkspaceEntityData",
|
||||
supertypes = listOf(), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = true)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId", entityDataFqName = "com.intellij.platform.workspace.storage.impl.WorkspaceEntityWithSymbolicIdData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "symbolicId", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.SymbolicEntityId")), withDefault = false)), extProperties = listOf(), isAbstract = true)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId",
|
||||
entityDataFqName = "com.intellij.platform.workspace.storage.impl.WorkspaceEntityWithSymbolicIdData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "symbolicId",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.SymbolicEntityId")),
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = true)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.WorkspaceEntity", metadataHash = 1885263617)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId", metadataHash = -272153521)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1637225356)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.DummyParentEntitySource", metadataHash = 1210649349)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.WorkspaceEntity", metadataHash = 1885263617)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.WorkspaceEntityWithSymbolicId", metadataHash = -272153521)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.EntitySource", metadataHash = 1637225356)
|
||||
addMetadataHash(typeFqn = "com.intellij.platform.workspace.storage.DummyParentEntitySource", metadataHash = 1210649349)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license.
|
||||
package com.intellij.platform.workspace.storage
|
||||
|
||||
import org.jetbrains.annotations.ApiStatus
|
||||
|
||||
@@ -64,6 +64,8 @@ jvm_library(
|
||||
"//platform/backend/workspace",
|
||||
"//platform/util/progress",
|
||||
"//platform/core-api:core",
|
||||
"//platform/workspace/jps",
|
||||
"//java/java-impl:impl",
|
||||
]
|
||||
)
|
||||
### auto-generated section `build intellij.devkit.workspaceModel` end
|
||||
@@ -61,5 +61,7 @@
|
||||
<orderEntry type="module" module-name="intellij.platform.backend.workspace" />
|
||||
<orderEntry type="module" module-name="intellij.platform.util.progress" />
|
||||
<orderEntry type="module" module-name="intellij.platform.core" />
|
||||
<orderEntry type="module" module-name="intellij.platform.workspace.jps" />
|
||||
<orderEntry type="module" module-name="intellij.java.impl" />
|
||||
</component>
|
||||
</module>
|
||||
@@ -216,7 +216,7 @@ internal class WorkspaceMetaModelBuilder(
|
||||
knownTypes: MutableMap<String, ValueType.Blob<*>>,
|
||||
hasParentAnnotation: Boolean,
|
||||
): ValueType<*> {
|
||||
if (type !is KaClassType) error("$type is not a class")
|
||||
if (type !is KaClassType) error("$type is not a class in module ${compiledObjModule.name}")
|
||||
if (type.nullability == KaTypeNullability.NULLABLE) {
|
||||
val nonNullableType = type.withNullability(KaTypeNullability.NON_NULLABLE)
|
||||
return ValueType.Optional(convertType(nonNullableType, knownTypes, hasParentAnnotation))
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
package com.intellij.devkit.workspaceModel
|
||||
|
||||
import com.intellij.devkit.workspaceModel.codegen.writer.CodeWriter
|
||||
import com.intellij.java.workspace.entities.JavaSourceRootPropertiesEntity
|
||||
import com.intellij.java.workspace.entities.javaSourceRoots
|
||||
import com.intellij.openapi.application.EDT
|
||||
import com.intellij.openapi.application.WriteAction
|
||||
import com.intellij.openapi.components.Service
|
||||
@@ -10,18 +12,22 @@ import com.intellij.openapi.diagnostic.logger
|
||||
import com.intellij.openapi.module.Module
|
||||
import com.intellij.openapi.project.DumbService
|
||||
import com.intellij.openapi.project.Project
|
||||
import com.intellij.openapi.roots.ModuleRootManager
|
||||
import com.intellij.openapi.roots.SourceFolder
|
||||
import com.intellij.openapi.vfs.VfsUtil
|
||||
import com.intellij.openapi.vfs.VfsUtilCore
|
||||
import com.intellij.openapi.vfs.VirtualFile
|
||||
import com.intellij.platform.backend.workspace.toVirtualFileUrl
|
||||
import com.intellij.platform.backend.workspace.virtualFile
|
||||
import com.intellij.platform.backend.workspace.workspaceModel
|
||||
import com.intellij.platform.workspace.jps.entities.ModuleEntity
|
||||
import com.intellij.platform.workspace.jps.entities.SourceRootEntity
|
||||
import com.intellij.platform.workspace.jps.entities.modifyContentRootEntity
|
||||
import com.intellij.platform.workspace.storage.MutableEntityStorage
|
||||
import com.intellij.workspaceModel.ide.legacyBridge.findModuleEntity
|
||||
import com.intellij.workspaceModel.ide.legacyBridge.findSnapshotModuleEntity
|
||||
import com.intellij.workspaceModel.ide.legacyBridge.impl.java.JAVA_TEST_ROOT_ENTITY_TYPE_ID
|
||||
import kotlinx.coroutines.CoroutineScope
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
import kotlinx.coroutines.withContext
|
||||
import org.jetbrains.jps.model.java.JavaSourceRootProperties
|
||||
import org.jetbrains.jps.model.java.JavaSourceRootType
|
||||
import org.jetbrains.jps.model.java.JpsJavaExtensionService
|
||||
import org.jetbrains.kotlin.config.ExplicitApiMode
|
||||
import org.jetbrains.kotlin.config.IKotlinFacetSettings
|
||||
import org.jetbrains.kotlin.config.additionalArgumentsAsList
|
||||
@@ -50,89 +56,74 @@ class WorkspaceModelGenerator(private val project: Project, private val coroutin
|
||||
}
|
||||
|
||||
private suspend fun onModule(module: Module) {
|
||||
val acceptedSourceRoots = getSourceRoot(module)
|
||||
if (acceptedSourceRoots.isEmpty()) {
|
||||
//val acceptedSourceRoots = getSourceRoot(module)
|
||||
val moduleEntity = module.findSnapshotModuleEntity() ?: module.findModuleEntity()
|
||||
if (moduleEntity == null) {
|
||||
LOG.info("Module entity not found")
|
||||
return
|
||||
}
|
||||
val sourceRoots = getSourceRoots(moduleEntity)
|
||||
if (sourceRoots.isEmpty()) {
|
||||
LOG.info("Acceptable module source roots not found")
|
||||
return
|
||||
}
|
||||
acceptedSourceRoots.forEach { sourceRoot ->
|
||||
sourceRoots.forEach { sourceRoot ->
|
||||
if (sourceRoot.url.virtualFile == null)
|
||||
return@forEach
|
||||
withContext(Dispatchers.EDT) {
|
||||
DumbService.getInstance(project).completeJustSubmittedTasks() // Waiting for smart mode
|
||||
CodeWriter.generate(
|
||||
project, module, sourceRoot.file!!,
|
||||
project, module, sourceRoot.url.virtualFile!!,
|
||||
processAbstractTypes = module.withAbstractTypes,
|
||||
explicitApiEnabled = module.explicitApiEnabled,
|
||||
isTestSourceFolder = sourceRoot.isTestSource,
|
||||
isTestSourceFolder = sourceRoot.rootTypeId == JAVA_TEST_ROOT_ENTITY_TYPE_ID,
|
||||
isTestModule = module.isTestModule, // TODO(It doesn't work for all modules)
|
||||
targetFolderGenerator = { createGeneratedSourceFolder(module, sourceRoot) },
|
||||
existingTargetFolder = { calculateExistingGenFolder(sourceRoot) }
|
||||
targetFolderGenerator = {
|
||||
WriteAction.compute<VirtualFile?, Throwable> {
|
||||
var genSourceRot: SourceRootEntity? = null
|
||||
project.workspaceModel.updateProjectModel("Create gen folder for ${moduleEntity.name}") {
|
||||
genSourceRot = createGenSourceRoot(it, sourceRoot)
|
||||
}
|
||||
genSourceRot?.url?.virtualFile
|
||||
}
|
||||
},
|
||||
existingTargetFolder = {
|
||||
calculateExistingGenFolder(sourceRoot)
|
||||
}
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun calculateExistingGenFolder(sourceFolder: SourceFolder): VirtualFile? {
|
||||
if (sourceFolder.contentEntry.file == sourceFolder.file) return null
|
||||
return sourceFolder.file?.parent?.children?.find {
|
||||
if (sourceFolder.isTestSource) {
|
||||
it.name == TEST_GENERATED_FOLDER_NAME
|
||||
} else {
|
||||
it.name == GENERATED_FOLDER_NAME
|
||||
}
|
||||
private fun calculateExistingGenFolder(sourceRoot: SourceRootEntity): VirtualFile? {
|
||||
val closest = sourceRoot.javaSourceRoots.firstOrNull { it.generated }
|
||||
if (closest != null) {
|
||||
return closest.sourceRoot.url.virtualFile
|
||||
}
|
||||
}
|
||||
|
||||
private fun createGeneratedSourceFolder(module: Module, sourceFolder: SourceFolder): VirtualFile? {
|
||||
// Create gen folder if it doesn't exist
|
||||
val generatedFolder = WriteAction.compute<VirtualFile, RuntimeException> {
|
||||
if (sourceFolder.isTestSource) {
|
||||
VfsUtil.createDirectoryIfMissing(sourceFolder.file?.parent, TEST_GENERATED_FOLDER_NAME)
|
||||
} else {
|
||||
VfsUtil.createDirectoryIfMissing(sourceFolder.file?.parent, GENERATED_FOLDER_NAME)
|
||||
}
|
||||
val contentRoot = sourceRoot.contentRoot
|
||||
val inContentRoot = contentRoot.sourceRoots.flatMap { it.javaSourceRoots }.firstOrNull { it.generated }
|
||||
if (inContentRoot != null) {
|
||||
return inContentRoot.sourceRoot.url.virtualFile
|
||||
}
|
||||
|
||||
val moduleRootManager = ModuleRootManager.getInstance(module)
|
||||
val modifiableModel = moduleRootManager.modifiableModel
|
||||
// Searching for the related content root
|
||||
for (contentEntry in modifiableModel.contentEntries) {
|
||||
val contentEntryFile = contentEntry.file
|
||||
if (contentEntryFile != null && VfsUtilCore.isAncestor(contentEntryFile, generatedFolder, false)) {
|
||||
// Checking if it already contains generation folder
|
||||
val existingGenFolder = contentEntry.sourceFolders.firstOrNull {
|
||||
(it.jpsElement.properties as? JavaSourceRootProperties)?.isForGeneratedSources == true &&
|
||||
it.file == generatedFolder
|
||||
}
|
||||
if (existingGenFolder != null) return generatedFolder
|
||||
// If it doesn't, create new get folder for the selected content root
|
||||
val properties = JpsJavaExtensionService.getInstance().createSourceRootProperties("", true)
|
||||
val sourceFolderType = if (sourceFolder.isTestSource) JavaSourceRootType.TEST_SOURCE else JavaSourceRootType.SOURCE
|
||||
contentEntry.addSourceFolder(generatedFolder, sourceFolderType, properties)
|
||||
WriteAction.run<RuntimeException>(modifiableModel::commit)
|
||||
return generatedFolder
|
||||
}
|
||||
}
|
||||
modifiableModel.dispose()
|
||||
return null
|
||||
}
|
||||
|
||||
private fun getSourceRoot(module: Module): List<SourceFolder> {
|
||||
val moduleRootManager = ModuleRootManager.getInstance(module)
|
||||
val contentEntries = moduleRootManager.contentEntries
|
||||
//val contentEntryFile = contentEntry.file
|
||||
//val sourceFolders = contentEntry.sourceFolders
|
||||
// if (contentEntryFile != null && VfsUtilCore.isAncestor(contentEntryFile, selectedFolder, false)) {
|
||||
// val sourceFolder = contentEntry.sourceFolders.firstOrNull { sourceRoot -> VfsUtil.isUnder(selectedFolder, setOf(sourceRoot.file)) }
|
||||
// if (sourceFolder != null) return sourceFolder
|
||||
// }
|
||||
//}
|
||||
return contentEntries.flatMap { it.sourceFolders.asIterable() }.filter {
|
||||
if (it.file == null) return@filter false
|
||||
if (it.rootType !is JavaSourceRootType) return@filter false
|
||||
val javaSourceRootProperties = it.jpsElement.properties as? JavaSourceRootProperties
|
||||
if (javaSourceRootProperties == null) return@filter true
|
||||
return@filter !javaSourceRootProperties.isForGeneratedSources
|
||||
private fun createGenSourceRoot(storage: MutableEntityStorage, sourceRoot: SourceRootEntity): SourceRootEntity {
|
||||
val genFolderName = if (sourceRoot.rootTypeId == JAVA_TEST_ROOT_ENTITY_TYPE_ID) TEST_GENERATED_FOLDER_NAME else GENERATED_FOLDER_NAME
|
||||
val genFolderVirtualFile = VfsUtil.createDirectories("${sourceRoot.contentRoot.url.presentableUrl}/$genFolderName")
|
||||
val javaSourceRoot = sourceRoot.javaSourceRoots.first()
|
||||
val updatedContentRoot = storage.modifyContentRootEntity(sourceRoot.contentRoot) {
|
||||
this.sourceRoots += SourceRootEntity(genFolderVirtualFile.toVirtualFileUrl(project.workspaceModel.getVirtualFileUrlManager()),
|
||||
sourceRoot.rootTypeId, sourceRoot.entitySource) {
|
||||
javaSourceRoots = listOf(JavaSourceRootPropertiesEntity(true, javaSourceRoot.packagePrefix, javaSourceRoot.entitySource))
|
||||
}
|
||||
}
|
||||
val result = updatedContentRoot.sourceRoots.last()
|
||||
return result
|
||||
}
|
||||
|
||||
private fun getSourceRoots(moduleEntity: ModuleEntity): List<SourceRootEntity> {
|
||||
return moduleEntity.contentRoots.flatMap { it.sourceRoots.flatMap { it.javaSourceRoots } }.filter { !it.generated }.map { it.sourceRoot }.distinct()
|
||||
}
|
||||
|
||||
private val Module.withAbstractTypes: Boolean
|
||||
|
||||
@@ -37,6 +37,8 @@ import org.jetbrains.kotlin.idea.formatter.kotlinCustomSettings
|
||||
import org.jetbrains.kotlin.lexer.KtTokens
|
||||
import org.jetbrains.kotlin.psi.*
|
||||
import org.jetbrains.kotlin.psi.psiUtil.children
|
||||
import org.jetbrains.kotlin.psi.psiUtil.isPublic
|
||||
import org.jetbrains.kotlin.psi.psiUtil.visibilityModifierType
|
||||
import org.jetbrains.kotlin.resolve.ImportPath
|
||||
import java.io.IOException
|
||||
import java.net.URL
|
||||
@@ -44,7 +46,6 @@ import java.util.*
|
||||
import java.util.jar.Manifest
|
||||
import kotlin.time.Duration.Companion.seconds
|
||||
|
||||
|
||||
private val LOG = logger<CodeWriter>()
|
||||
|
||||
object CodeWriter {
|
||||
@@ -118,12 +119,16 @@ object CodeWriter {
|
||||
return@runWriteActionWithCancellableProgressInDispatchThread
|
||||
}
|
||||
|
||||
val genFolder = targetFolderGenerator.invoke()
|
||||
val genFolder = existingTargetFolder.invoke() ?: targetFolderGenerator.invoke()
|
||||
if (genFolder == null) {
|
||||
LOG.info("Generated source folder doesn't exist. Skip processing source folder with path: ${sourceFolder}")
|
||||
return@runWriteActionWithCancellableProgressInDispatchThread
|
||||
}
|
||||
|
||||
// compatibility invoke in FacetEntity and KotlinSettingsEntity
|
||||
val savedCompatibilityInvokeCode = mutableMapOf<KtClass, PsiElement>()
|
||||
saveCompatibilityCode(ktClasses, savedCompatibilityInvokeCode)
|
||||
|
||||
indicator.text = DevKitWorkspaceModelBundle.message("progress.text.removing.old.code")
|
||||
removeGeneratedCode(ktClasses, genFolder)
|
||||
|
||||
@@ -149,7 +154,8 @@ object CodeWriter {
|
||||
code, generatedFiles, project,
|
||||
sourceFolder, genFolder,
|
||||
ktClasses, importsByFile,
|
||||
topLevelDeclarations, psiFactory
|
||||
topLevelDeclarations, psiFactory,
|
||||
savedCompatibilityInvokeCode
|
||||
)
|
||||
}
|
||||
}
|
||||
@@ -160,7 +166,7 @@ object CodeWriter {
|
||||
|
||||
CodeStyle.runWithLocalSettings(project, CodeStyle.getSettings(project)) { localSettings ->
|
||||
localSettings.setUpCodeStyle()
|
||||
generatedFiles.withoutBigFiles().forEachIndexed { i, file ->
|
||||
generatedFiles.forEachIndexed { i, file ->
|
||||
indicator.fraction = 0.25 + 0.7 * i / generatedFiles.size
|
||||
CodeStyleManager.getInstance(project).reformat(file)
|
||||
file.apiFileNameForImplFile?.let { ktClasses[it] }?.containingKtFile?.let { apiFile -> copyHeaderComment(apiFile, file) }
|
||||
@@ -284,6 +290,16 @@ object CodeWriter {
|
||||
val metadataStorageImplementation = codeGenerator.generateMetadataStoragesImplementation(objModules, generatorSettings)
|
||||
return entitiesImplementations + metadataStorageImplementation
|
||||
}
|
||||
|
||||
private fun saveCompatibilityCode(ktClasses: Map<String, KtClass>, savedCompatibilityInvokeCode: MutableMap<KtClass, PsiElement>) {
|
||||
for (ktClass in ktClasses.values) {
|
||||
val companionDeclaration = ktClass.body?.declarations?.find { it is KtObjectDeclaration && it.isCompanion() } as? KtObjectDeclaration
|
||||
?: continue
|
||||
val compatibilityInvoke = companionDeclaration.declarations.find { it is KtNamedFunction && it.name == "create" && it.annotationEntries.any { it.shortName.toString() == "Deprecated" } }
|
||||
?: continue
|
||||
savedCompatibilityInvokeCode[ktClass] = compatibilityInvoke.copy()
|
||||
}
|
||||
}
|
||||
|
||||
private fun removeGeneratedCode(ktClasses: Map<String, KtClass>, genFolder: VirtualFile) {
|
||||
ktClasses.values.flatMapTo(HashSet()) { listOfNotNull(it.containingFile.node, it.body?.node) }.forEach {
|
||||
@@ -340,20 +356,31 @@ object CodeWriter {
|
||||
code: ObjClassGeneratedCode, generatedFiles: MutableList<KtFile>,
|
||||
project: Project, sourceFolder: VirtualFile, genFolder: VirtualFile,
|
||||
ktClasses: Map<String, KtClass>, importsByFile: MutableMap<KtFile, Imports>,
|
||||
topLevelDeclarations: MultiMap<KtFile, Pair<KtClass, List<KtDeclaration>>>, psiFactory: KtPsiFactory,
|
||||
topLevelDeclarations: MultiMap<KtFile, Pair<KtClass, List<KtDeclaration>>>, psiFactory: KtPsiFactory,
|
||||
savedCompatibilityInvokeCode: MutableMap<KtClass, PsiElement>,
|
||||
) {
|
||||
|
||||
if (code.target.name in SKIPPED_TYPES) return
|
||||
|
||||
val target = code.target
|
||||
val apiInterfaceName = "${target.module.name}.${target.name}"
|
||||
val apiClass = ktClasses[apiInterfaceName] ?: error("Cannot find API class by $apiInterfaceName")
|
||||
val apiClass = ktClasses[apiInterfaceName]
|
||||
if (apiClass == null) {
|
||||
LOG.warn("Class $apiInterfaceName was not found")
|
||||
return
|
||||
}
|
||||
val apiFile = apiClass.containingKtFile
|
||||
val apiImports = importsByFile.getValue(apiFile)
|
||||
addInnerDeclarations(apiClass, code, apiImports)
|
||||
addInnerDeclarations(apiClass, code, apiImports, savedCompatibilityInvokeCode)
|
||||
val topLevelCode = code.topLevelCode
|
||||
if (topLevelCode != null) {
|
||||
val declarations = psiFactory.createFile(apiImports.findAndRemoveFqns(code.topLevelCode!!)).declarations
|
||||
val declarations = psiFactory.createFile(apiImports.findAndRemoveFqns(code.topLevelCode!!))
|
||||
.declarations.also {
|
||||
if (!apiClass.isPublic) {
|
||||
val apiClassVisibilityModifierType = apiClass.visibilityModifierType()!!
|
||||
it.forEach { declaration -> declaration.addModifier(apiClassVisibilityModifierType) }
|
||||
}
|
||||
}
|
||||
topLevelDeclarations.putValue(apiFile, apiClass to declarations)
|
||||
}
|
||||
val implementationClassText = code.implementationClass
|
||||
@@ -412,13 +439,23 @@ object CodeWriter {
|
||||
}
|
||||
}
|
||||
|
||||
private fun addInnerDeclarations(ktClass: KtClass, code: ObjClassGeneratedCode, imports: Imports) {
|
||||
private fun addInnerDeclarations(ktClass: KtClass, code: ObjClassGeneratedCode, imports: Imports, savedCompatibilityInvokeCode: MutableMap<KtClass, PsiElement>) {
|
||||
val psiFactory = KtPsiFactory(ktClass.project)
|
||||
val builderInterface = ktClass.addDeclaration(psiFactory.createClass(imports.findAndRemoveFqns(code.builderInterface)))
|
||||
val companionObject = ktClass.addDeclaration(psiFactory.createObject(imports.findAndRemoveFqns(code.companionObject)))
|
||||
val body = ktClass.getOrCreateBody()
|
||||
addGeneratedRegionStartComment(body, builderInterface)
|
||||
addGeneratedRegionEndComment(body, companionObject)
|
||||
|
||||
val compatibilityInvoke = savedCompatibilityInvokeCode.remove(ktClass) ?: return
|
||||
addCompatibilityInvoke(companionObject, compatibilityInvoke, psiFactory)
|
||||
}
|
||||
|
||||
private fun addCompatibilityInvoke(companionObject: KtObjectDeclaration, compatibilityInvoke: PsiElement, psiFactory: KtPsiFactory) {
|
||||
val companionBody = companionObject.getOrCreateBody()
|
||||
companionBody.addBefore(compatibilityInvoke, companionBody.rBrace)
|
||||
companionBody.addBefore(psiFactory.createNewLine(), companionBody.rBrace)
|
||||
companionBody.addBefore(psiFactory.createComment(GENERATED_COMPATIBILITY_REGION_END), companionBody.rBrace)
|
||||
}
|
||||
|
||||
private fun addGeneratedRegionStartComment(parent: KtElement, place: KtElement) {
|
||||
@@ -481,6 +518,7 @@ object CodeWriter {
|
||||
return "${packageFqName.asString().dropLast(4)}${name.dropLast(7)}"
|
||||
}
|
||||
|
||||
// generated region
|
||||
private const val GENERATED_REGION_START = "//region generated code"
|
||||
|
||||
private const val GENERATED_REGION_END = "//endregion"
|
||||
@@ -492,7 +530,11 @@ object CodeWriter {
|
||||
private val ASTNode.isGeneratedRegionEnd: Boolean
|
||||
get() =
|
||||
elementType == KtTokens.EOL_COMMENT && text == GENERATED_REGION_END
|
||||
|
||||
// compatability region
|
||||
private const val GENERATED_COMPATIBILITY_REGION_START = "//region compatibility generated code"
|
||||
|
||||
private const val GENERATED_COMPATIBILITY_REGION_END = "//endregion compatibility generated code"
|
||||
|
||||
private const val GENERATED_METADATA_STORAGE_FILE = "MetadataStorageImpl.kt"
|
||||
|
||||
@@ -501,7 +543,6 @@ object CodeWriter {
|
||||
private val VirtualFile.isGeneratedFile: Boolean
|
||||
get() = extension == "kt" && GENERATED_FILES.contains(name)
|
||||
|
||||
|
||||
private object CodegenApiVersion {
|
||||
const val JSON_RELATIVE_PATH = "codegen-api-metadata.json"
|
||||
const val MANIFEST_RELATIVE_PATH = "META-INF/MANIFEST.MF"
|
||||
|
||||
@@ -47,6 +47,7 @@ jvm_library(
|
||||
"//plugins/kotlin/tests-common:tests-common_test_lib",
|
||||
"@lib//:rd-core",
|
||||
"@lib//:rd-framework",
|
||||
"//platform/util/jdom",
|
||||
],
|
||||
runtime_deps = ["//plugins/devkit"]
|
||||
)
|
||||
|
||||
@@ -37,5 +37,6 @@
|
||||
<orderEntry type="module" module-name="kotlin.tests-common" />
|
||||
<orderEntry type="library" name="rd-core" level="project" />
|
||||
<orderEntry type="library" name="rd-framework" level="project" />
|
||||
<orderEntry type="module" module-name="intellij.platform.util.jdom" />
|
||||
</component>
|
||||
</module>
|
||||
@@ -9,20 +9,28 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.SimpleEntity", entityDataFqName = "com.intellij.workspaceModel.test.api.impl.SimpleEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.SimpleEntity",
|
||||
entityDataFqName = "com.intellij.workspaceModel.test.api.impl.SimpleEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.SimpleEntity", metadataHash = -282990951)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.SimpleEntity", metadataHash = -282990951)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -46,8 +46,8 @@ internal class SimpleEntityImpl(private val dataSource: SimpleEntityData) : Simp
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: SimpleEntityData?) : ModifiableWorkspaceEntityBase<SimpleEntity, SimpleEntityData>(result),
|
||||
SimpleEntity.Builder {
|
||||
internal class Builder(result: SimpleEntityData?) : ModifiableWorkspaceEntityBase<SimpleEntity, SimpleEntityData>(
|
||||
result), SimpleEntity.Builder {
|
||||
internal constructor() : this(SimpleEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
package com.intellij.workspaceModel.test.api
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
import com.intellij.platform.workspace.storage.EntityType
|
||||
import com.intellij.platform.workspace.storage.GeneratedCodeApiVersion
|
||||
import com.intellij.platform.workspace.storage.MutableEntityStorage
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntity
|
||||
|
||||
interface SimpleEntity : WorkspaceEntity {
|
||||
val version: Int
|
||||
val name: String
|
||||
val isSimple: Boolean
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<SimpleEntity> {
|
||||
override var entitySource: EntitySource
|
||||
var version: Int
|
||||
var name: String
|
||||
var isSimple: Boolean
|
||||
}
|
||||
|
||||
companion object : EntityType<SimpleEntity, Builder>() {
|
||||
@JvmOverloads
|
||||
@JvmStatic
|
||||
@JvmName("create")
|
||||
operator fun invoke(
|
||||
version: Int,
|
||||
name: String,
|
||||
isSimple: Boolean,
|
||||
entitySource: EntitySource,
|
||||
init: (Builder.() -> Unit)? = null,
|
||||
): Builder {
|
||||
val builder = builder()
|
||||
builder.version = version
|
||||
builder.name = name
|
||||
builder.isSimple = isSimple
|
||||
builder.entitySource = entitySource
|
||||
init?.invoke(builder)
|
||||
return builder
|
||||
}
|
||||
|
||||
//region compatibility generated code
|
||||
@Deprecated(
|
||||
message = "This method is deprecated and will be removed in next major release",
|
||||
replaceWith = ReplaceWith("invoke(version, name, isSimple, entitySource, init)"),
|
||||
)
|
||||
@JvmOverloads
|
||||
@JvmStatic
|
||||
@JvmName("create")
|
||||
fun create(
|
||||
name: String,
|
||||
version: Int,
|
||||
isSimple: Boolean,
|
||||
entitySource: EntitySource,
|
||||
init: (Builder.() -> Unit)? = null,
|
||||
): Builder = invoke(version, name, isSimple, entitySource, init)
|
||||
//endregion compatibility generated code
|
||||
}
|
||||
//endregion
|
||||
}
|
||||
|
||||
//region generated code
|
||||
fun MutableEntityStorage.modifySimpleEntity(
|
||||
entity: SimpleEntity,
|
||||
modification: SimpleEntity.Builder.() -> Unit,
|
||||
): SimpleEntity = modifyEntity(SimpleEntity.Builder::class.java, entity, modification)
|
||||
//endregion
|
||||
@@ -0,0 +1,43 @@
|
||||
package com.intellij.workspaceModel.test.api.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
import com.intellij.platform.workspace.storage.metadata.impl.MetadataStorageBase
|
||||
import com.intellij.platform.workspace.storage.metadata.model.EntityMetadata
|
||||
import com.intellij.platform.workspace.storage.metadata.model.FinalClassMetadata
|
||||
import com.intellij.platform.workspace.storage.metadata.model.OwnPropertyMetadata
|
||||
import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadata
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeBooleanNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Boolean")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.SimpleEntity",
|
||||
entityDataFqName = "com.intellij.workspaceModel.test.api.impl.SimpleEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "version", valueType = primitiveTypeIntNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "isSimple",
|
||||
valueType = primitiveTypeBooleanNotNullable, withDefault = false)), extProperties = listOf(),
|
||||
isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.SimpleEntity", metadataHash = 513917454)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,235 @@
|
||||
package com.intellij.workspaceModel.test.api.impl
|
||||
|
||||
import com.intellij.platform.workspace.storage.ConnectionId
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
import com.intellij.platform.workspace.storage.EntityType
|
||||
import com.intellij.platform.workspace.storage.GeneratedCodeApiVersion
|
||||
import com.intellij.platform.workspace.storage.GeneratedCodeImplVersion
|
||||
import com.intellij.platform.workspace.storage.MutableEntityStorage
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntity
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntityInternalApi
|
||||
import com.intellij.platform.workspace.storage.impl.ModifiableWorkspaceEntityBase
|
||||
import com.intellij.platform.workspace.storage.impl.WorkspaceEntityBase
|
||||
import com.intellij.platform.workspace.storage.impl.WorkspaceEntityData
|
||||
import com.intellij.platform.workspace.storage.instrumentation.EntityStorageInstrumentation
|
||||
import com.intellij.platform.workspace.storage.instrumentation.EntityStorageInstrumentationApi
|
||||
import com.intellij.platform.workspace.storage.metadata.model.EntityMetadata
|
||||
import com.intellij.workspaceModel.test.api.SimpleEntity
|
||||
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class SimpleEntityImpl(private val dataSource: SimpleEntityData) : SimpleEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
)
|
||||
|
||||
}
|
||||
|
||||
override val version: Int
|
||||
get() {
|
||||
readField("version")
|
||||
return dataSource.version
|
||||
}
|
||||
override val name: String
|
||||
get() {
|
||||
readField("name")
|
||||
return dataSource.name
|
||||
}
|
||||
|
||||
override val isSimple: Boolean
|
||||
get() {
|
||||
readField("isSimple")
|
||||
return dataSource.isSimple
|
||||
}
|
||||
|
||||
override val entitySource: EntitySource
|
||||
get() {
|
||||
readField("entitySource")
|
||||
return dataSource.entitySource
|
||||
}
|
||||
|
||||
override fun connectionIdList(): List<ConnectionId> {
|
||||
return connections
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: SimpleEntityData?) : ModifiableWorkspaceEntityBase<SimpleEntity, SimpleEntityData>(
|
||||
result), SimpleEntity.Builder {
|
||||
internal constructor() : this(SimpleEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
if (this.diff != null) {
|
||||
if (existsInBuilder(builder)) {
|
||||
this.diff = builder
|
||||
return
|
||||
}
|
||||
else {
|
||||
error("Entity SimpleEntity is already created in a different builder")
|
||||
}
|
||||
}
|
||||
|
||||
this.diff = builder
|
||||
addToBuilder()
|
||||
this.id = getEntityData().createEntityId()
|
||||
// After adding entity data to the builder, we need to unbind it and move the control over entity data to builder
|
||||
// Builder may switch to snapshot at any moment and lock entity data to modification
|
||||
this.currentEntityData = null
|
||||
|
||||
// Process linked entities that are connected without a builder
|
||||
processLinkedEntities(builder)
|
||||
checkInitialization() // TODO uncomment and check failed tests
|
||||
}
|
||||
|
||||
private fun checkInitialization() {
|
||||
val _diff = diff
|
||||
if (!getEntityData().isEntitySourceInitialized()) {
|
||||
error("Field WorkspaceEntity#entitySource should be initialized")
|
||||
}
|
||||
if (!getEntityData().isNameInitialized()) {
|
||||
error("Field SimpleEntity#name should be initialized")
|
||||
}
|
||||
}
|
||||
|
||||
override fun connectionIdList(): List<ConnectionId> {
|
||||
return connections
|
||||
}
|
||||
|
||||
// Relabeling code, move information from dataSource to this builder
|
||||
override fun relabel(dataSource: WorkspaceEntity, parents: Set<WorkspaceEntity>?) {
|
||||
dataSource as SimpleEntity
|
||||
if (this.entitySource != dataSource.entitySource) this.entitySource = dataSource.entitySource
|
||||
if (this.version != dataSource.version) this.version = dataSource.version
|
||||
if (this.name != dataSource.name) this.name = dataSource.name
|
||||
if (this.isSimple != dataSource.isSimple) this.isSimple = dataSource.isSimple
|
||||
updateChildToParentReferences(parents)
|
||||
}
|
||||
|
||||
|
||||
override var entitySource: EntitySource
|
||||
get() = getEntityData().entitySource
|
||||
set(value) {
|
||||
checkModificationAllowed()
|
||||
getEntityData(true).entitySource = value
|
||||
changedProperty.add("entitySource")
|
||||
|
||||
}
|
||||
|
||||
override var version: Int
|
||||
get() = getEntityData().version
|
||||
set(value) {
|
||||
checkModificationAllowed()
|
||||
getEntityData(true).version = value
|
||||
changedProperty.add("version")
|
||||
}
|
||||
|
||||
override var name: String
|
||||
get() = getEntityData().name
|
||||
set(value) {
|
||||
checkModificationAllowed()
|
||||
getEntityData(true).name = value
|
||||
changedProperty.add("name")
|
||||
}
|
||||
|
||||
override var isSimple: Boolean
|
||||
get() = getEntityData().isSimple
|
||||
set(value) {
|
||||
checkModificationAllowed()
|
||||
getEntityData(true).isSimple = value
|
||||
changedProperty.add("isSimple")
|
||||
}
|
||||
|
||||
override fun getEntityClass(): Class<SimpleEntity> = SimpleEntity::class.java
|
||||
}
|
||||
}
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class SimpleEntityData : WorkspaceEntityData<SimpleEntity>() {
|
||||
var version: Int = 0
|
||||
lateinit var name: String
|
||||
var isSimple: Boolean = false
|
||||
|
||||
|
||||
internal fun isNameInitialized(): Boolean = ::name.isInitialized
|
||||
|
||||
|
||||
override fun wrapAsModifiable(diff: MutableEntityStorage): WorkspaceEntity.Builder<SimpleEntity> {
|
||||
val modifiable = SimpleEntityImpl.Builder(null)
|
||||
modifiable.diff = diff
|
||||
modifiable.id = createEntityId()
|
||||
return modifiable
|
||||
}
|
||||
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
override fun createEntity(snapshot: EntityStorageInstrumentation): SimpleEntity {
|
||||
val entityId = createEntityId()
|
||||
return snapshot.initializeEntity(entityId) {
|
||||
val entity = SimpleEntityImpl(this)
|
||||
entity.snapshot = snapshot
|
||||
entity.id = entityId
|
||||
entity
|
||||
}
|
||||
}
|
||||
|
||||
override fun getMetadata(): EntityMetadata {
|
||||
return MetadataStorageImpl.getMetadataByTypeFqn("com.intellij.workspaceModel.test.api.SimpleEntity") as EntityMetadata
|
||||
}
|
||||
|
||||
override fun getEntityInterface(): Class<out WorkspaceEntity> {
|
||||
return SimpleEntity::class.java
|
||||
}
|
||||
|
||||
override fun createDetachedEntity(parents: List<WorkspaceEntity.Builder<*>>): WorkspaceEntity.Builder<*> {
|
||||
return SimpleEntity(version, name, isSimple, entitySource) {
|
||||
}
|
||||
}
|
||||
|
||||
override fun getRequiredParents(): List<Class<out WorkspaceEntity>> {
|
||||
val res = mutableListOf<Class<out WorkspaceEntity>>()
|
||||
return res
|
||||
}
|
||||
|
||||
override fun equals(other: Any?): Boolean {
|
||||
if (other == null) return false
|
||||
if (this.javaClass != other.javaClass) return false
|
||||
|
||||
other as SimpleEntityData
|
||||
|
||||
if (this.entitySource != other.entitySource) return false
|
||||
if (this.version != other.version) return false
|
||||
if (this.name != other.name) return false
|
||||
if (this.isSimple != other.isSimple) return false
|
||||
return true
|
||||
}
|
||||
|
||||
override fun equalsIgnoringEntitySource(other: Any?): Boolean {
|
||||
if (other == null) return false
|
||||
if (this.javaClass != other.javaClass) return false
|
||||
|
||||
other as SimpleEntityData
|
||||
|
||||
if (this.version != other.version) return false
|
||||
if (this.name != other.name) return false
|
||||
if (this.isSimple != other.isSimple) return false
|
||||
return true
|
||||
}
|
||||
|
||||
override fun hashCode(): Int {
|
||||
var result = entitySource.hashCode()
|
||||
result = 31 * result + version.hashCode()
|
||||
result = 31 * result + name.hashCode()
|
||||
result = 31 * result + isSimple.hashCode()
|
||||
return result
|
||||
}
|
||||
|
||||
override fun hashCodeIgnoringEntitySource(): Int {
|
||||
var result = javaClass.hashCode()
|
||||
result = 31 * result + version.hashCode()
|
||||
result = 31 * result + name.hashCode()
|
||||
result = 31 * result + isSimple.hashCode()
|
||||
return result
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,72 @@
|
||||
package com.intellij.workspaceModel.test.api
|
||||
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntity
|
||||
|
||||
import com.intellij.platform.workspace.storage.EntitySource
|
||||
import com.intellij.platform.workspace.storage.EntityType
|
||||
import com.intellij.platform.workspace.storage.GeneratedCodeApiVersion
|
||||
import com.intellij.platform.workspace.storage.MutableEntityStorage
|
||||
import com.intellij.platform.workspace.storage.WorkspaceEntity
|
||||
|
||||
interface SimpleEntity : WorkspaceEntity {
|
||||
val version: Int
|
||||
val name: String
|
||||
val isSimple: Boolean
|
||||
|
||||
//region generated code
|
||||
@GeneratedCodeApiVersion(3)
|
||||
interface Builder : WorkspaceEntity.Builder<SimpleEntity> {
|
||||
override var entitySource: EntitySource
|
||||
var version: Int
|
||||
var name: String
|
||||
var isSimple: Boolean
|
||||
}
|
||||
|
||||
companion object : EntityType<SimpleEntity, Builder>() {
|
||||
@JvmOverloads
|
||||
@JvmStatic
|
||||
@JvmName("create")
|
||||
operator fun invoke(
|
||||
version: Int,
|
||||
name: String,
|
||||
isSimple: Boolean,
|
||||
entitySource: EntitySource,
|
||||
init: (Builder.() -> Unit)? = null,
|
||||
): Builder {
|
||||
val builder = builder()
|
||||
builder.version = version
|
||||
builder.name = name
|
||||
builder.isSimple = isSimple
|
||||
builder.entitySource = entitySource
|
||||
init?.invoke(builder)
|
||||
return builder
|
||||
}
|
||||
|
||||
//region compatibility generated code
|
||||
@Deprecated(
|
||||
message = "This method is deprecated and will be removed in next major release",
|
||||
replaceWith = ReplaceWith("invoke(version, name, isSimple, entitySource, init)"),
|
||||
)
|
||||
@JvmOverloads
|
||||
@JvmStatic
|
||||
@JvmName("create")
|
||||
fun create(
|
||||
name: String,
|
||||
version: Int,
|
||||
isSimple: Boolean,
|
||||
entitySource: EntitySource,
|
||||
init: (Builder.() -> Unit)? = null,
|
||||
): Builder = invoke(version, name, isSimple, entitySource, init)
|
||||
//endregion compatibility generated code
|
||||
}
|
||||
//endregion
|
||||
}
|
||||
|
||||
//region generated code
|
||||
fun MutableEntityStorage.modifySimpleEntity(
|
||||
entity: SimpleEntity,
|
||||
modification: SimpleEntity.Builder.() -> Unit,
|
||||
): SimpleEntity {
|
||||
return modifyEntity(SimpleEntity.Builder::class.java, entity, modification)
|
||||
}
|
||||
//endregion
|
||||
@@ -24,8 +24,8 @@ import com.intellij.workspaceModel.test.api.TestData
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class DefaultFieldEntityImpl(private val dataSource: DefaultFieldEntityData) : DefaultFieldEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class DefaultFieldEntityImpl(private val dataSource: DefaultFieldEntityData) : DefaultFieldEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
|
||||
@@ -67,8 +67,8 @@ internal class DefaultFieldEntityImpl(private val dataSource: DefaultFieldEntity
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: DefaultFieldEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<DefaultFieldEntity, DefaultFieldEntityData>(result), DefaultFieldEntity.Builder {
|
||||
internal class Builder(result: DefaultFieldEntityData?) : ModifiableWorkspaceEntityBase<DefaultFieldEntity, DefaultFieldEntityData>(
|
||||
result), DefaultFieldEntity.Builder {
|
||||
internal constructor() : this(DefaultFieldEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -9,33 +9,63 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeSetNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Set")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
val primitiveTypeMapNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Map")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeSetNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Set")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
val primitiveTypeMapNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Map")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.DefaultFieldEntity", entityDataFqName = "com.intellij.workspaceModel.test.api.impl.DefaultFieldEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "version", valueType = primitiveTypeIntNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "data", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.ClassMetadata(fqName = "com.intellij.workspaceModel.test.api.TestData", properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "description", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false)), supertypes = listOf())), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "anotherVersion", valueType = primitiveTypeIntNotNullable, withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "description", valueType = primitiveTypeStringNotNullable, withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "defaultSet", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable), primitive = primitiveTypeSetNotNullable), withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "defaultList", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable), primitive = primitiveTypeListNotNullable), withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "defaultMap", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable,
|
||||
primitiveTypeStringNotNullable), primitive = primitiveTypeMapNotNullable), withDefault = true)), extProperties = listOf(), isAbstract = false)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.DefaultFieldEntity",
|
||||
entityDataFqName = "com.intellij.workspaceModel.test.api.impl.DefaultFieldEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "version", valueType = primitiveTypeIntNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "data",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.ClassMetadata(
|
||||
fqName = "com.intellij.workspaceModel.test.api.TestData",
|
||||
properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false,
|
||||
name = "description",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false,
|
||||
isOpen = false, name = "name",
|
||||
valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false)),
|
||||
supertypes = listOf())), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "anotherVersion",
|
||||
valueType = primitiveTypeIntNotNullable, withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "description",
|
||||
valueType = primitiveTypeStringNotNullable, withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "defaultSet",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable),
|
||||
primitive = primitiveTypeSetNotNullable), withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "defaultList",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable),
|
||||
primitive = primitiveTypeListNotNullable), withDefault = true),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "defaultMap",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable,
|
||||
primitiveTypeStringNotNullable),
|
||||
primitive = primitiveTypeMapNotNullable), withDefault = true)),
|
||||
extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.DefaultFieldEntity", metadataHash = -116709851)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.TestData", metadataHash = -898117917)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.DefaultFieldEntity", metadataHash = -116709851)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.TestData", metadataHash = -898117917)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -24,15 +24,14 @@ import com.intellij.workspaceModel.test.api.SimpleEntity
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class ChildrenCollectionFieldEntityImpl(private val dataSource: ChildrenCollectionFieldEntityData) : ChildrenCollectionFieldEntity,
|
||||
WorkspaceEntityBase(
|
||||
dataSource
|
||||
) {
|
||||
internal class ChildrenCollectionFieldEntityImpl(private val dataSource: ChildrenCollectionFieldEntityData) : ChildrenCollectionFieldEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val CHILDRENENTITIESCOLLECTION_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ChildrenCollectionFieldEntity::class.java, SimpleEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false
|
||||
)
|
||||
internal val CHILDRENENTITIESCOLLECTION_CONNECTION_ID: ConnectionId = ConnectionId.create(ChildrenCollectionFieldEntity::class.java,
|
||||
SimpleEntity::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_MANY,
|
||||
false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
CHILDRENENTITIESCOLLECTION_CONNECTION_ID,
|
||||
@@ -60,9 +59,8 @@ internal class ChildrenCollectionFieldEntityImpl(private val dataSource: Childre
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ChildrenCollectionFieldEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<ChildrenCollectionFieldEntity, ChildrenCollectionFieldEntityData>(result),
|
||||
ChildrenCollectionFieldEntity.Builder {
|
||||
internal class Builder(result: ChildrenCollectionFieldEntityData?) : ModifiableWorkspaceEntityBase<ChildrenCollectionFieldEntity, ChildrenCollectionFieldEntityData>(
|
||||
result), ChildrenCollectionFieldEntity.Builder {
|
||||
internal constructor() : this(ChildrenCollectionFieldEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -147,8 +145,8 @@ internal class ChildrenCollectionFieldEntityImpl(private val dataSource: Childre
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDRENENTITIESCOLLECTION_CONNECTION_ID, this)!!
|
||||
.toList() as List<SimpleEntity.Builder>) +
|
||||
((_diff as MutableEntityStorageInstrumentation).getManyChildrenBuilders(CHILDRENENTITIESCOLLECTION_CONNECTION_ID,
|
||||
this)!!.toList() as List<SimpleEntity.Builder>) +
|
||||
(this.entityLinks[EntityLink(true, CHILDRENENTITIESCOLLECTION_CONNECTION_ID)] as? List<SimpleEntity.Builder> ?: emptyList())
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -10,32 +10,58 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeBooleanNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Boolean")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeBooleanNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Boolean")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.ChildrenCollectionFieldEntity", entityDataFqName = "com.intellij.workspaceModel.test.api.impl.ChildrenCollectionFieldEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "childrenEntitiesCollection", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_MANY, entityFqName = "com.intellij.workspaceModel.test.api.SimpleEntity", isChild = true, isNullable = false), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.ChildrenCollectionFieldEntity",
|
||||
entityDataFqName = "com.intellij.workspaceModel.test.api.impl.ChildrenCollectionFieldEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "childrenEntitiesCollection",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_MANY,
|
||||
entityFqName = "com.intellij.workspaceModel.test.api.SimpleEntity",
|
||||
isChild = true, isNullable = false), withDefault = false)),
|
||||
extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
addMetadata(typeMetadata)
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.SimpleEntity", entityDataFqName = "com.intellij.workspaceModel.test.api.impl.SimpleEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "version", valueType = primitiveTypeIntNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "isSimple", valueType = primitiveTypeBooleanNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parent", valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_MANY, entityFqName = "com.intellij.workspaceModel.test.api.ChildrenCollectionFieldEntity", isChild = false, isNullable = false), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.SimpleEntity",
|
||||
entityDataFqName = "com.intellij.workspaceModel.test.api.impl.SimpleEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "version", valueType = primitiveTypeIntNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "name", valueType = primitiveTypeStringNotNullable,
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "isSimple",
|
||||
valueType = primitiveTypeBooleanNotNullable, withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "parent",
|
||||
valueType = ValueTypeMetadata.EntityReference(connectionType = ConnectionId.ConnectionType.ONE_TO_MANY,
|
||||
entityFqName = "com.intellij.workspaceModel.test.api.ChildrenCollectionFieldEntity",
|
||||
isChild = false, isNullable = false), withDefault = false)),
|
||||
extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.ChildrenCollectionFieldEntity", metadataHash = -454547805)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.SimpleEntity", metadataHash = -41718252)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.ChildrenCollectionFieldEntity", metadataHash = -454547805)
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.SimpleEntity", metadataHash = -41718252)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -27,9 +27,9 @@ import com.intellij.workspaceModel.test.api.SimpleEntity
|
||||
internal class SimpleEntityImpl(private val dataSource: SimpleEntityData) : SimpleEntity, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENT_CONNECTION_ID: ConnectionId = ConnectionId.create(
|
||||
ChildrenCollectionFieldEntity::class.java, SimpleEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY, false
|
||||
)
|
||||
internal val PARENT_CONNECTION_ID: ConnectionId = ConnectionId.create(ChildrenCollectionFieldEntity::class.java,
|
||||
SimpleEntity::class.java, ConnectionId.ConnectionType.ONE_TO_MANY,
|
||||
false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENT_CONNECTION_ID,
|
||||
@@ -67,8 +67,8 @@ internal class SimpleEntityImpl(private val dataSource: SimpleEntityData) : Simp
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: SimpleEntityData?) : ModifiableWorkspaceEntityBase<SimpleEntity, SimpleEntityData>(result),
|
||||
SimpleEntity.Builder {
|
||||
internal class Builder(result: SimpleEntityData?) : ModifiableWorkspaceEntityBase<SimpleEntity, SimpleEntityData>(
|
||||
result), SimpleEntity.Builder {
|
||||
internal constructor() : this(SimpleEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
@@ -167,9 +167,8 @@ internal class SimpleEntityImpl(private val dataSource: SimpleEntityData) : Simp
|
||||
val _diff = diff
|
||||
return if (_diff != null) {
|
||||
@OptIn(EntityStorageInstrumentationApi::class)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(
|
||||
PARENT_CONNECTION_ID, this
|
||||
) as? ChildrenCollectionFieldEntity.Builder)
|
||||
((_diff as MutableEntityStorageInstrumentation).getParentBuilder(PARENT_CONNECTION_ID,
|
||||
this) as? ChildrenCollectionFieldEntity.Builder)
|
||||
?: (this.entityLinks[EntityLink(false, PARENT_CONNECTION_ID)]!! as ChildrenCollectionFieldEntity.Builder)
|
||||
}
|
||||
else {
|
||||
|
||||
@@ -22,8 +22,8 @@ import com.intellij.workspaceModel.test.api.CollectionFieldEntity
|
||||
@GeneratedCodeApiVersion(3)
|
||||
@GeneratedCodeImplVersion(7)
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal class CollectionFieldEntityImpl(private val dataSource: CollectionFieldEntityData) : CollectionFieldEntity,
|
||||
WorkspaceEntityBase(dataSource) {
|
||||
internal class CollectionFieldEntityImpl(private val dataSource: CollectionFieldEntityData) : CollectionFieldEntity, WorkspaceEntityBase(
|
||||
dataSource) {
|
||||
|
||||
private companion object {
|
||||
|
||||
@@ -62,8 +62,8 @@ internal class CollectionFieldEntityImpl(private val dataSource: CollectionField
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: CollectionFieldEntityData?) :
|
||||
ModifiableWorkspaceEntityBase<CollectionFieldEntity, CollectionFieldEntityData>(result), CollectionFieldEntity.Builder {
|
||||
internal class Builder(result: CollectionFieldEntityData?) : ModifiableWorkspaceEntityBase<CollectionFieldEntity, CollectionFieldEntityData>(
|
||||
result), CollectionFieldEntity.Builder {
|
||||
internal constructor() : this(CollectionFieldEntityData())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
@@ -9,27 +9,41 @@ import com.intellij.platform.workspace.storage.metadata.model.StorageTypeMetadat
|
||||
import com.intellij.platform.workspace.storage.metadata.model.ValueTypeMetadata
|
||||
|
||||
@OptIn(WorkspaceEntityInternalApi::class)
|
||||
internal object MetadataStorageImpl: MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeSetNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Set")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
val primitiveTypeMapNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Map")
|
||||
internal object MetadataStorageImpl : MetadataStorageBase() {
|
||||
override fun initializeMetadata() {
|
||||
val primitiveTypeIntNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Int")
|
||||
val primitiveTypeSetNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Set")
|
||||
val primitiveTypeStringNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "String")
|
||||
val primitiveTypeListNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "List")
|
||||
val primitiveTypeMapNotNullable = ValueTypeMetadata.SimpleType.PrimitiveType(isNullable = false, type = "Map")
|
||||
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
var typeMetadata: StorageTypeMetadata
|
||||
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.CollectionFieldEntity", entityDataFqName = "com.intellij.workspaceModel.test.api.impl.CollectionFieldEntityData", supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource", valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false, typeMetadata = FinalClassMetadata.KnownClass(fqName = "com.intellij.platform.workspace.storage.EntitySource")), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "versions", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeIntNotNullable), primitive = primitiveTypeSetNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "names", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable), primitive = primitiveTypeListNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "manifestAttributes", valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable,
|
||||
primitiveTypeStringNotNullable), primitive = primitiveTypeMapNotNullable), withDefault = false)), extProperties = listOf(), isAbstract = false)
|
||||
typeMetadata = EntityMetadata(fqName = "com.intellij.workspaceModel.test.api.CollectionFieldEntity",
|
||||
entityDataFqName = "com.intellij.workspaceModel.test.api.impl.CollectionFieldEntityData",
|
||||
supertypes = listOf("com.intellij.platform.workspace.storage.WorkspaceEntity"), properties = listOf(
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "entitySource",
|
||||
valueType = ValueTypeMetadata.SimpleType.CustomType(isNullable = false,
|
||||
typeMetadata = FinalClassMetadata.KnownClass(
|
||||
fqName = "com.intellij.platform.workspace.storage.EntitySource")),
|
||||
withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "versions",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeIntNotNullable),
|
||||
primitive = primitiveTypeSetNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "names",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable),
|
||||
primitive = primitiveTypeListNotNullable), withDefault = false),
|
||||
OwnPropertyMetadata(isComputable = false, isKey = false, isOpen = false, name = "manifestAttributes",
|
||||
valueType = ValueTypeMetadata.ParameterizedType(generics = listOf(primitiveTypeStringNotNullable,
|
||||
primitiveTypeStringNotNullable),
|
||||
primitive = primitiveTypeMapNotNullable), withDefault = false)),
|
||||
extProperties = listOf(), isAbstract = false)
|
||||
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
addMetadata(typeMetadata)
|
||||
}
|
||||
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.CollectionFieldEntity", metadataHash = 1555273165)
|
||||
}
|
||||
override fun initializeMetadataHash() {
|
||||
addMetadataHash(typeFqn = "com.intellij.workspaceModel.test.api.CollectionFieldEntity", metadataHash = 1555273165)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -27,8 +27,8 @@ import com.intellij.workspaceModel.test.api.EntityWithChildren
|
||||
internal class ChildEntityType1Impl(private val dataSource: ChildEntityType1Data) : ChildEntityType1, WorkspaceEntityBase(dataSource) {
|
||||
|
||||
private companion object {
|
||||
internal val PARENT_CONNECTION_ID: ConnectionId =
|
||||
ConnectionId.create(EntityWithChildren::class.java, ChildEntityType1::class.java, ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
internal val PARENT_CONNECTION_ID: ConnectionId = ConnectionId.create(EntityWithChildren::class.java, ChildEntityType1::class.java,
|
||||
ConnectionId.ConnectionType.ONE_TO_ONE, false)
|
||||
|
||||
private val connections = listOf<ConnectionId>(
|
||||
PARENT_CONNECTION_ID,
|
||||
@@ -55,8 +55,8 @@ internal class ChildEntityType1Impl(private val dataSource: ChildEntityType1Data
|
||||
}
|
||||
|
||||
|
||||
internal class Builder(result: ChildEntityType1Data?) : ModifiableWorkspaceEntityBase<ChildEntityType1, ChildEntityType1Data>(result),
|
||||
ChildEntityType1.Builder {
|
||||
internal class Builder(result: ChildEntityType1Data?) : ModifiableWorkspaceEntityBase<ChildEntityType1, ChildEntityType1Data>(
|
||||
result), ChildEntityType1.Builder {
|
||||
internal constructor() : this(ChildEntityType1Data())
|
||||
|
||||
override fun applyToBuilder(builder: MutableEntityStorage) {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user