Skip to content

Commit

Permalink
Adds entity type and asset with uuid for DAM
Browse files Browse the repository at this point in the history
  • Loading branch information
metakernel committed Aug 12, 2024
1 parent 7e5c0ad commit ff92b8f
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 7 deletions.
19 changes: 13 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,26 @@ path = "src/lib.rs"

[dependencies]
notify = "6.1.1"
libloading = "0.8.3"
clap = {version = "4.5.7", features = ["derive"]}
libloading = "0.8.5"
clap = {version = "4.5.15", features = ["derive"]}
paw = "1.0.0"
interprocess = "2.2.0"
interprocess = "2.2.1"
dirs = "5.0.1"
petgraph = "0.6.5"
blake2 = "0.10.6"
uuid = "1.8.0"

# Specific dependencies for the gawires kernel
gawires-diff = { git = "https://github.com/metakernel/gawires-diff"}
gawires-patch = { git = "https://github.com/metakernel/gawires-diff"}

[dependencies.uuid]
version = "1.10.0"
features = [
"v4", # Lets you generate random UUIDs
"fast-rng", # Use a faster (but still sufficiently random) RNG
"macro-diagnostics", # Enable better diagnostics for compile-time UUIDs
]


[target.'cfg(unix)'.dependencies]
# Used for the filesystem in linux and macos
Expand All @@ -44,7 +51,7 @@ fuser = "0.14.0"
[target.'cfg(windows)'.dependencies]
# Used for the filesystem in windows
dokan = "0.3.1+dokan206"
windows = "0.57.0"
windows = "0.58.0"

[target.'cfg(windows)'.build-dependencies]
windows = "0.57.0"
windows = "0.58.0"
8 changes: 7 additions & 1 deletion src/core/asset.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
pub mod version_graph;
pub mod entity;
pub mod asset_proxy;
pub mod asset_tag;

use uuid::Uuid;
use version_graph::VersionGraph;

// Représente un UUID pour chaque entité
type AssetId = Uuid;

pub struct Asset {
pub uuid: Uuid,
pub id: AssetId,
pub name: String,
pub version_graph: VersionGraph,

Expand Down
12 changes: 12 additions & 0 deletions src/core/asset/entity.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
pub mod entity_component;

use uuid::Uuid;

// Représente un UUID pour chaque entité
type EntityId = Uuid;
///
pub struct Entity{
pub id: EntityId,
pub components: Vec<Uuid>,

}

0 comments on commit ff92b8f

Please sign in to comment.