Last change
on this file since 69 was 67, checked in by Bart Vastenhouw, 3 years ago |
Added SAOP and simplerunner to GeniusWebPython. Several minor fixes.
|
File size:
698 bytes
|
Line | |
---|
1 | from decimal import Decimal
|
---|
2 | from typing import Dict
|
---|
3 |
|
---|
4 | from geniusweb.profile.utilityspace.UtilitySpace import UtilitySpace
|
---|
5 | from geniusweb.profile.utilityspace.ValueSetUtilities import ValueSetUtilities
|
---|
6 |
|
---|
7 |
|
---|
8 | class LinearAdditive ( UtilitySpace):
|
---|
9 | '''
|
---|
10 | interface to a Utilityspace that is linear-additive.
|
---|
11 |
|
---|
12 | '''
|
---|
13 | def getUtilities(self) -> Dict[str, ValueSetUtilities] :
|
---|
14 | '''
|
---|
15 | @return the map from issue names to valuesetutilities (un-weighted)
|
---|
16 | '''
|
---|
17 |
|
---|
18 | def getWeights(self) -> Dict[str, Decimal] :
|
---|
19 | '''
|
---|
20 | @return the map from issue names to weights. weights sum to 1.
|
---|
21 | '''
|
---|
22 |
|
---|
23 | def getWeight(self, issue:str) -> Decimal: '''
|
---|
24 | @param issue the issue name
|
---|
25 | @return the weight of the given issue
|
---|
26 | '''
|
---|
27 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.