Index: /issm/trunk-jpl/src/m/classes/pairoptions.m
===================================================================
--- /issm/trunk-jpl/src/m/classes/pairoptions.m	(revision 14175)
+++ /issm/trunk-jpl/src/m/classes/pairoptions.m	(revision 14176)
@@ -5,8 +5,8 @@
 %      pairoptions=pairoptions('module',true,'solver',false);
 
-classdef pairoptions
+classdef pairoptions < handle
 	properties (SetAccess = private,GetAccess = private) 
 		functionname = '';
-		list         = cell(0,2);
+		list         = cell(0,3);
 	end
 	methods
@@ -38,5 +38,5 @@
 
 			%Allocate memory
-			obj.list=cell(numoptions,2);
+			obj.list=cell(numoptions,3);
 
 			%go through varargin and build list of obj
@@ -45,4 +45,5 @@
 					obj.list{i,1}=varargin{2*i-1};
 					obj.list{i,2}=varargin{2*i};
+					obj.list{i,3}=false; %used?
 				else
 					%option is not a string, ignore it
@@ -57,4 +58,5 @@
 				obj.list{end+1,1} = field;
 				obj.list{end,2}   = value;
+				obj.list{end,3}   = false;
 			end
 		end % }}}
@@ -65,4 +67,5 @@
 					obj.list{end+1,1} = field;
 					obj.list{end,2}   = value;
+					obj.list{end,3}   = true;  %It is a default so user will not be notified if not used
 				end
 			end
@@ -91,4 +94,5 @@
 				%add new field if not found
 				obj=addfield(obj,field,newvalue);
+				obj.list{end,3}=true; % do not notify user if unused
 			else
 				for i=1:length(lines),
@@ -116,4 +120,14 @@
 			%remove duplicates from the options list
 			obj.list=obj.list(lines,:);
+		end % }}}
+		function displayunused(obj) % {{{
+			%DISPLAYUNUSED - display unused options
+
+			numoptions=size(obj.list,1);
+			for i=1:numoptions,
+				if ~obj.list{i,3},
+					disp(['WARNING: option ' obj.list{i,1} ' was not used'])
+				end
+			end
 		end % }}}
 		function disp(obj) % {{{
@@ -187,5 +201,6 @@
 			pos=find(strcmpi(obj.list(:,1),field));
 			if ~isempty(pos),
-				value=obj.list{pos(1),2}; %ignore extra entry
+				value=obj.list{pos(1),2}; % ignore extra entry
+				obj.list{pos(1),3}=true;  % option used
 				return;
 			end
