# ProjectUnits

Assignment allocation, where 100 percent is one full resource unit.

Struct 

`OfficeIMO.Project`

**Namespace**

`OfficeIMO.Project`

**Assembly**

`OfficeIMO.Project`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[ProjectDuration.cs:180](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Project/Model/ProjectDuration.cs#L180)

**Base**

`ValueType`

**Implements**

`IEquatable<ProjectUnits>`

**Modifiers**

sealed

Assignment allocation, where 100 percent is one full resource unit.

## Inheritance

- ValueType
- ProjectUnits

## Usage

Explore 13 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 7

- Property [ProjectAssignment.Units](/api/project/officeimo-project-projectassignment/#property-units)
- Property [ProjectAssignmentSchedule.Units](/api/project/officeimo-project-projectassignmentschedule/#property-units)
- Property [ProjectResource.MaxUnits](/api/project/officeimo-project-projectresource/#property-maxunits)
- Property [ProjectResourceAvailability.Units](/api/project/officeimo-project-projectresourceavailability/#property-units)
- Method [ProjectUnits.Fraction](/api/project/officeimo-project-projectunits/#method-fraction-decimal)
- Method [ProjectUnits.Percent](/api/project/officeimo-project-projectunits/#method-percent-decimal)
- Method [ProjectWorkEquation.Units](/api/project/officeimo-project-projectworkequation/#method-units-officeimo-project-projectwork-decimal)

### Accepted by parameters 6

- Method [ProjectAssignmentCollection.Add](/api/project/officeimo-project-projectassignmentcollection/#method-add-officeimo-project-projecttask-officeimo-project-projectresource-nullable-officeimo-project-projectunits) parameter `units`
- Method [ProjectResource.SetMaxUnits](/api/project/officeimo-project-projectresource/#method-setmaxunits-officeimo-project-projectunits) parameter `value`
- Method [ProjectTask.Assign](/api/project/officeimo-project-projecttask/#method-assign-string-nullable-officeimo-project-projectunits) parameter `units`
- Method [ProjectUnits.Equals](/api/project/officeimo-project-projectunits/#method-equals-officeimo-project-projectunits) parameter `other`
- Method [ProjectWorkEquation.DurationMinutes](/api/project/officeimo-project-projectworkequation/#method-durationminutes-officeimo-project-projectwork-officeimo-project-projectunits) parameter `totalUnits`
- Method [ProjectWorkEquation.Work](/api/project/officeimo-project-projectworkequation/#method-work-decimal-officeimo-project-projectunits) parameter `units`

Filter members 

Show inherited

## Methods

Equals 2 overloads

`public bool Equals(ProjectUnits other)` [#](#method-equals-officeimo-project-projectunits)

[ProjectDuration.cs:184](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Project/Model/ProjectDuration.cs#L184)

Indicates whether the current object is equal to another object of the same type.

Parameters

**other OfficeIMO.Project.ProjectUnits required**

An object to compare with this object.

Returns

`bool` true if the current object is equal to the other parameter; otherwise, false.

`public override bool Equals(object? obj)` [#](#method-equals-object)

[ProjectDuration.cs:186](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Project/Model/ProjectDuration.cs#L186)

Indicates whether this instance and a specified object are equal.

Parameters

**obj object? required**

The object to compare with the current instance.

Returns

`bool` true if obj and this instance are the same type and represent the same value; otherwise, false.

`public static ProjectUnits Fraction(decimal value)` [#](#method-fraction-decimal)

[ProjectDuration.cs:182](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Project/Model/ProjectDuration.cs#L182)

Creates fractional resource units such as 0.5 or 1.

Parameters

**value decimal required**

Returns

`ProjectUnits`

`public override int GetHashCode()` [#](#method-gethashcode)

[ProjectDuration.cs:188](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Project/Model/ProjectDuration.cs#L188)

Returns the hash code for this instance.

Returns

`int` A 32-bit signed integer that is the hash code for this instance.

`public static ProjectUnits Percent(decimal value)` [#](#method-percent-decimal)

[ProjectDuration.cs:180](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Project/Model/ProjectDuration.cs#L180)

Creates allocation from a percent such as 50 or 100.

Parameters

**value decimal required**

Returns

`ProjectUnits`

## Inherited Methods

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public override string? ToString()` [#](#method-tostring)

Inherited from ValueType

Returns

`string?`

## Properties

`public decimal Value { get; }` [#](#property-value)

[ProjectDuration.cs:178](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Project/Model/ProjectDuration.cs#L178)

Fractional units; 1 means 100 percent.

<!-- PowerForge markdown artifact sha256:3C35E9D4FE36B1EAA05F14F928F4D6DC76190D82A3420B4B90C8CD6F42B54E4A -->
