Holdings¶
An
Opinion
’s announcement that it posits or rejects a legalRule
.Note that if an opinion merely says the court is not deciding whether a
Rule
is valid, there is noHolding
, and noRule
object should be created. Deciding not to decide aRule
’s validity is not the same thing as deciding that theRule
is undecided.- Parameters
rule (Rule) – a statement of a legal doctrine about a
Procedure
for litigation.rule_valid (bool) –
True
means theRule
is asserted to be valid (or useable by a court in litigation).False
means it’s asserted to be invalid.decided (bool) –
False
means that it should be deemed undecided whether theRule
is valid, and thus can have the effect of overruling prior holdings finding theRule
to be either valid or invalid. Seemingly,decided=False
should render therule_valid
flag irrelevant.exclusive (bool) – if True, the stated rule is asserted to be the only way to establish the output that is the output of the rule.
generic (bool) – if True, indicates that the specific attributes of this holding are irrelevant in the context of a different holding that is referencing this holding.
Call
Procedure
’scontext_factors()
method.- Return type
- Returns
context_factors from
self
’sProcedure
Get
Factor
s that can be replaced without changingself
s meaning.
Find context matches that would result in a contradiction with other.
- Parameters
other (
Factor
) – TheFactor
to be compared to self. Unlike withcontradicts()
, this method cannot be called with anOpinion
for other.- Return type
Iterator
[Explanation
]- Returns
a generator yielding
ContextRegister
s that cause a contradiction.
Test if
self
implies()
other
negated()
.Works by testing whether
self
would implyother
ifother
had an opposite value forrule_valid
.This method takes three main paths depending on whether the holdings
self
andother
assert that rules are decided or undecided.A
decided
Rule
can never contradict a previous statement that anyRule
was undecided.If rule A implies rule B, then a holding that B is undecided contradicts a prior
Rule
deciding that rule A is valid or invalid.- Return type
- Returns
whether
self
contradictsother
.
Test for implication.
See
Procedure.implies_all_to_all()
andProcedure.implies_all_to_some()
for explanations of howinputs
,outputs
, anddespite
Factor
s affect implication.
Generate
ContextRegister
s that cause self to imply other.If self is absent, then generate a ContextRegister from other’s point of view and then swap the keys and values.
- Return type
Iterator
[Explanation
]
Test if other implies self.
This function is for handling implication checks for classes that don’t know the structure of the
Holding
class, such asFact
andRule
.- Return type
Yield
Holding
s that can be inferred from the “exclusive” flag.The generator will be empty if self.exclusive is False.
Make new object with attributes from
self.__dict__
, replacing attributes as specified.- Parameters
changes (
Union
[str
,Sequence
[str
],Dict
[str
,Any
]]) – adict
where the keys are names of attributes of self, and the values are new values for those attributes, or else an attribute name orlist
of names that need to have their values replaced with their boolean opposite.- Return type
- Returns
a new object initialized with attributes from
self.__dict__
, except that any attributes named as keys in the changes parameter are replaced by the corresponding value.
Generate ways to match contexts of self and other so they mean the same.
- Return type
Iterator
[ContextRegister
]
Test whether
other
has the same meaning asself
.
Get new copy of
self
with an opposite value forrule_valid
.
Create new
Holding
, replacing keys ofchanges
with values.- Return type
- Returns
a version of
self
with the new context.
Infer a Holding from all inputs and outputs of self and other, in context.
Return attributes of
self
that aren’t inherited from another class.Used for getting parameters to pass to
__init__()
when generating a new object.
Return str(self).