aboutsummaryrefslogtreecommitdiff
path: root/src/waifu.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/waifu.rs')
-rw-r--r--src/waifu.rs14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/waifu.rs b/src/waifu.rs
index da9653f..bb99d2b 100644
--- a/src/waifu.rs
+++ b/src/waifu.rs
@@ -8,7 +8,7 @@ use crate::errors::Error;
* Defines the amount of memory a waifu has
*/
#[derive(Debug, Serialize, Deserialize)]
-pub struct Memory(u64);
+pub struct Memory(pub u64);
impl From<u64> for Memory {
fn from(u: u64) -> Self {
@@ -16,16 +16,11 @@ impl From<u64> for Memory {
}
}
-impl Memory {
- pub fn count(&self) -> u64 {
- self.0
- }
-}
/**
* Defines the number of vCPUs a waifu has
*/
#[derive(Debug, Serialize, Deserialize)]
-pub struct CpuCount(u64);
+pub struct CpuCount(pub u64);
impl From<u64> for CpuCount {
fn from(u: u64) -> Self {
@@ -33,11 +28,6 @@ impl From<u64> for CpuCount {
}
}
-impl CpuCount {
- pub fn count(&self) -> u64 {
- self.0
- }
-}
/**
* Represents a virtual machine, that's active on some server
*