Salome HOME
Merge from BR_QT4 17Feb09
[tools/hxx2salome.git] / scripts / parse1.awk
index f1d085fdea2eed09dd29b1c71c78de0588e6b9e7..455ab957365349bf118b038edee163550ba280a1 100644 (file)
@@ -1,11 +1,16 @@
 # This awk program extract public functions of the class definition present in hxx interface
+# --
+# Copyright (C) CEA, EDF
+# Author : Nicolas Crouzet (CEA)
+# --
 
 BEGIN { public=0 }
 
 # we want to extract each function that is public and that does'nt contain
-# the patterns : public, private, // (comments), { and }
+# the patterns : public, protected, private, // (comments), { and }
 public == 1     && 
 $1 !~ /public/  && 
+$1 !~ /protected/ && 
 $1 !~ /private/ && 
 $1 !~ /\/\/*/   && 
 $1 !~ /{|}/  {
@@ -18,5 +23,6 @@ $1 !~ /{|}/  {
    
 $1 == "class" && $0 !~ /;/ {public=1} # we test matching against /;/  to get rid of forward declaration
 $1 ~ /public/ {public=1}
+$1 ~ /protected/ {public=0}
 $1 ~ /private/ {public=0}
 $1 ~ /}/      {public=0}