Add else statements
@@ -164,6 +164,7 @@ class Vertex(JavaObjectWrapper, SupportsRound['Vertex']):
def __round__(self, ndigits: Optional[int] = 0) -> 'Vertex':
if ndigits != 0:
raise NotImplementedError("Keanu only supports rounding to 0 digits")
+ else:
return kn.vertex.generated.Round(self)
def __floor__(self) -> 'Vertex':
@@ -233,49 +234,49 @@ class Integer(Vertex):
def __add__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.CastToDouble(self).__add__(other)
-
+ else:
return kn.vertex.generated.IntegerAddition(self, other)
def __radd__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.CastToDouble(self).__radd__(other)
-
+ else:
return kn.vertex.generated.IntegerAddition(other, self)
def __sub__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.generated.CastToDouble(self).__sub__(other)
-
+ else:
return kn.vertex.generated.IntegerDifference(self, other)
def __rsub__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.CastToDouble(self).__rsub__(other)
-
+ else:
return kn.vertex.generated.IntegerDifference(other, self)
def __mul__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.generated.CastToDouble(self).__mul__(other)
-
+ else:
return kn.vertex.generated.IntegerMultiplication(self, other)
def __rmul__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.CastToDouble(self).__rmul__(other)
-
+ else:
return kn.vertex.generated.IntegerMultiplication(other, self)
def __pow__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.generated.CastToDouble(self).__pow__(other)
-
+ else:
return kn.vertex.generated.IntegerPower(self, other)
def __rpow__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.CastToDouble(self).__rpow__(other)
-
+ else:
return kn.vertex.generated.IntegerPower(other, self)
def __truediv__(self, other: vertex_operation_param_types) -> 'Vertex':
@@ -287,13 +288,13 @@ class Integer(Vertex):
def __floordiv__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.generated.CastToDouble(self).__truediv__(other).__floor__()
-
+ else:
return kn.vertex.generated.IntegerDivision(self, other)
def __rfloordiv__(self, other: vertex_operation_param_types) -> 'Vertex':
if is_floating_type(other):
return kn.vertex.generated.CastToDouble(self).__rtruediv__(other).__floor__()
-
+ else:
return kn.vertex.generated.IntegerDivision(other, self)
