diff --git a/ApplicationCode/GrpcInterface/Python/rips/Case.py b/ApplicationCode/GrpcInterface/Python/rips/Case.py index 897bc68f95..9cfe254ce0 100644 --- a/ApplicationCode/GrpcInterface/Python/rips/Case.py +++ b/ApplicationCode/GrpcInterface/Python/rips/Case.py @@ -128,7 +128,21 @@ class Case (PdmObject): return receivedActiveCells def timeSteps(self): - """Get a list containing time step strings for all time steps""" + """Get a list containing all time steps + + The time steps are defined by the class **TimeStepDate** : + + Type | Name + --------- | ---------- + int | year + int | month + int | day + int | hour + int | minute + int | second + + + """ return self.stub.GetTimeSteps(self.request).dates def daysSinceStart(self): diff --git a/ApplicationCode/GrpcInterface/Python/rips/PythonExamples/AllCases.py b/ApplicationCode/GrpcInterface/Python/rips/PythonExamples/AllCases.py index 91d2db22c3..51d07a0b44 100644 --- a/ApplicationCode/GrpcInterface/Python/rips/PythonExamples/AllCases.py +++ b/ApplicationCode/GrpcInterface/Python/rips/PythonExamples/AllCases.py @@ -1,6 +1,6 @@ ################################################################################### # This example will connect to ResInsight, retrieve a list of cases and print info -# Also creates a new view for all cases +# ################################################################################### # Import the ResInsight Processing Server Module @@ -16,7 +16,11 @@ if resInsight is not None: for case in cases: print("Case name: " + case.name) print("Case grid path: " + case.gridPath()) - # Create a new view - view = case.createView() + + timesteps = case.timeSteps() + for t in timesteps: + print("Year: " + str(t.year)) + print("Month: " + str(t.month)) +