changeset 911:f7306f03f77a feature/utux2D

Improve comments and names. Change InterfaceOptions.union to merge.
author Martin Almquist <malmquist@stanford.edu>
date Sat, 24 Nov 2018 15:43:34 -0800
parents b9c98661ff5d
children 1cdf5ead2a16
files +multiblock/InterfaceOptions.m
diffstat 1 files changed, 7 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
diff -r b9c98661ff5d -r f7306f03f77a +multiblock/InterfaceOptions.m
--- a/+multiblock/InterfaceOptions.m	Fri Nov 23 20:39:40 2018 -0800
+++ b/+multiblock/InterfaceOptions.m	Sat Nov 24 15:43:34 2018 -0800
@@ -54,7 +54,7 @@
         %
         % optStr  -- string
         % val     -- anything
-        % i,j     -- integers
+        % i,j     -- integers (or empty)
         function setOption(obj, optStr, val, i ,j)
             default_arg('i',[]);
             default_arg('j',[]);
@@ -93,10 +93,12 @@
         end
 
 
-        % Constructs the union of two InterfaceOptions
-        function union(obj, obj2)
-            localOpts = obj.optsCell;
-            remoteOpts = obj2.optsCell;
+        % Merges with another InterfaceOptions-object.
+        % Errors if there are merge conflicts.
+        % TODO: merge with preference?
+        function merge(obj, obj2)
+            localOpts = obj.getOptions();
+            remoteOpts = obj2.getOptions();
 
             assert( numel(localOpts) == numel(remoteOpts), ...
                     'multiblock.InterfaceOptions: The two InterfaceOptions do not have the same dimension.');