ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/trunk/src/applications/staticProps/StaticPropsCmd.cpp
(Generate patch)

Comparing trunk/src/applications/staticProps/StaticPropsCmd.c (file contents):
Revision 1128 by chuckv, Wed Apr 11 23:27:20 2007 UTC vs.
Revision 1180 by chuckv, Mon Sep 17 20:05:51 2007 UTC

# Line 1 | Line 1
1   /*
2    File autogenerated by gengetopt version 2.19.1
3    generated with the following command:
4 <  gengetopt -i StaticProps.ggo -F StaticPropsCmd -u
4 >  gengetopt --file-name=StaticPropsCmd -u
5  
6    The developers of gengetopt consider the fixed text that goes in all
7    gengetopt output files to be in the public domain:
# Line 51 | Line 51 | const char *gengetopt_args_info_help[] = {
51    "\n Group: staticProps\n   an option of this group is required",
52    "      --bo                      bond order parameter (--rcut must be specified)",
53    "      --bor                     bond order parameter as a function of radius \n                                  (--rcut must be specified)",
54 +  "      --bad                     N(theta) bond angle density within (--rcut must \n                                  be specified)",
55    "  -g, --gofr                    g(r)",
56    "      --r_theta                 g(r, cos(theta))",
57    "      --r_omega                 g(r, cos(omega))",
# Line 63 | Line 64 | const char *gengetopt_args_info_help[] = {
64    "      --slab_density            slab density",
65    "      --hxy                     hxy",
66    "      --rho_r                   rho of R",
67 +  "      --hullvol                 hull volume of nanoparticle",
68      0
69   };
70  
# Line 105 | Line 107 | void clear_given (struct gengetopt_args_info *args_inf
107    args_info->radius_given = 0 ;
108    args_info->bo_given = 0 ;
109    args_info->bor_given = 0 ;
110 +  args_info->bad_given = 0 ;
111    args_info->gofr_given = 0 ;
112    args_info->r_theta_given = 0 ;
113    args_info->r_omega_given = 0 ;
# Line 117 | Line 120 | void clear_given (struct gengetopt_args_info *args_inf
120    args_info->slab_density_given = 0 ;
121    args_info->hxy_given = 0 ;
122    args_info->rho_r_given = 0 ;
123 +  args_info->hullvol_given = 0 ;
124    args_info->staticProps_group_counter = 0 ;
125   }
126  
# Line 182 | Line 186 | void init_args_info(struct gengetopt_args_info *args_i
186    args_info->radius_help = gengetopt_args_info_help[19] ;
187    args_info->bo_help = gengetopt_args_info_help[20] ;
188    args_info->bor_help = gengetopt_args_info_help[21] ;
189 <  args_info->gofr_help = gengetopt_args_info_help[22] ;
190 <  args_info->r_theta_help = gengetopt_args_info_help[23] ;
191 <  args_info->r_omega_help = gengetopt_args_info_help[24] ;
192 <  args_info->theta_omega_help = gengetopt_args_info_help[25] ;
193 <  args_info->gxyz_help = gengetopt_args_info_help[26] ;
194 <  args_info->p2_help = gengetopt_args_info_help[27] ;
195 <  args_info->rp2_help = gengetopt_args_info_help[28] ;
196 <  args_info->scd_help = gengetopt_args_info_help[29] ;
197 <  args_info->density_help = gengetopt_args_info_help[30] ;
198 <  args_info->slab_density_help = gengetopt_args_info_help[31] ;
199 <  args_info->hxy_help = gengetopt_args_info_help[32] ;
200 <  args_info->rho_r_help = gengetopt_args_info_help[33] ;
189 >  args_info->bad_help = gengetopt_args_info_help[22] ;
190 >  args_info->gofr_help = gengetopt_args_info_help[23] ;
191 >  args_info->r_theta_help = gengetopt_args_info_help[24] ;
192 >  args_info->r_omega_help = gengetopt_args_info_help[25] ;
193 >  args_info->theta_omega_help = gengetopt_args_info_help[26] ;
194 >  args_info->gxyz_help = gengetopt_args_info_help[27] ;
195 >  args_info->p2_help = gengetopt_args_info_help[28] ;
196 >  args_info->rp2_help = gengetopt_args_info_help[29] ;
197 >  args_info->scd_help = gengetopt_args_info_help[30] ;
198 >  args_info->density_help = gengetopt_args_info_help[31] ;
199 >  args_info->slab_density_help = gengetopt_args_info_help[32] ;
200 >  args_info->hxy_help = gengetopt_args_info_help[33] ;
201 >  args_info->rho_r_help = gengetopt_args_info_help[34] ;
202 >  args_info->hullvol_help = gengetopt_args_info_help[35] ;
203    
204   }
205  
# Line 523 | Line 529 | cmdline_parser_file_save(const char *filename, struct
529    }
530    if (args_info->bor_given) {
531      fprintf(outfile, "%s\n", "bor");
532 +  }
533 +  if (args_info->bad_given) {
534 +    fprintf(outfile, "%s\n", "bad");
535    }
536    if (args_info->gofr_given) {
537      fprintf(outfile, "%s\n", "gofr");
# Line 559 | Line 568 | cmdline_parser_file_save(const char *filename, struct
568    }
569    if (args_info->rho_r_given) {
570      fprintf(outfile, "%s\n", "rho_r");
571 +  }
572 +  if (args_info->hullvol_given) {
573 +    fprintf(outfile, "%s\n", "hullvol");
574    }
575    
576    fclose (outfile);
# Line 601 | Line 613 | reset_group_staticProps(struct gengetopt_args_info *ar
613    
614    args_info->bo_given = 0 ;
615    args_info->bor_given = 0 ;
616 +  args_info->bad_given = 0 ;
617    args_info->gofr_given = 0 ;
618    args_info->r_theta_given = 0 ;
619    args_info->r_omega_given = 0 ;
# Line 613 | Line 626 | reset_group_staticProps(struct gengetopt_args_info *ar
626    args_info->slab_density_given = 0 ;
627    args_info->hxy_given = 0 ;
628    args_info->rho_r_given = 0 ;
629 +  args_info->hullvol_given = 0 ;
630  
631    args_info->staticProps_group_counter = 0;
632   }
# Line 726 | Line 740 | cmdline_parser_internal (int argc, char * const *argv,
740          { "radius",     1, NULL, 0 },
741          { "bo", 0, NULL, 0 },
742          { "bor",        0, NULL, 0 },
743 +        { "bad",        0, NULL, 0 },
744          { "gofr",       0, NULL, 'g' },
745          { "r_theta",    0, NULL, 0 },
746          { "r_omega",    0, NULL, 0 },
# Line 738 | Line 753 | cmdline_parser_internal (int argc, char * const *argv,
753          { "slab_density",       0, NULL, 0 },
754          { "hxy",        0, NULL, 0 },
755          { "rho_r",      0, NULL, 0 },
756 +        { "hullvol",    0, NULL, 0 },
757          { NULL, 0, NULL, 0 }
758        };
759  
# Line 1204 | Line 1220 | cmdline_parser_internal (int argc, char * const *argv,
1220                continue;
1221              local_args_info.bor_given = 1;
1222              args_info->bor_given = 1;
1223 +            if (args_info->staticProps_group_counter && override)
1224 +              reset_group_staticProps (args_info);
1225 +            args_info->staticProps_group_counter += 1;
1226 +            break;
1227 +          }
1228 +          /* N(theta) bond angle density within (--rcut must be specified).  */
1229 +          else if (strcmp (long_options[option_index].name, "bad") == 0)
1230 +          {
1231 +            if (local_args_info.bad_given)
1232 +              {
1233 +                fprintf (stderr, "%s: `--bad' option given more than once%s\n", argv[0], (additional_error ? additional_error : ""));
1234 +                goto failure;
1235 +              }
1236 +            if (args_info->bad_given && ! override)
1237 +              continue;
1238 +            local_args_info.bad_given = 1;
1239 +            args_info->bad_given = 1;
1240              if (args_info->staticProps_group_counter && override)
1241                reset_group_staticProps (args_info);
1242              args_info->staticProps_group_counter += 1;
# Line 1345 | Line 1378 | cmdline_parser_internal (int argc, char * const *argv,
1378              args_info->staticProps_group_counter += 1;
1379              break;
1380            }
1381 +          /* hull volume of nanoparticle.  */
1382 +          else if (strcmp (long_options[option_index].name, "hullvol") == 0)
1383 +          {
1384 +            if (local_args_info.hullvol_given)
1385 +              {
1386 +                fprintf (stderr, "%s: `--hullvol' option given more than once%s\n", argv[0], (additional_error ? additional_error : ""));
1387 +                goto failure;
1388 +              }
1389 +            if (args_info->hullvol_given && ! override)
1390 +              continue;
1391 +            local_args_info.hullvol_given = 1;
1392 +            args_info->hullvol_given = 1;
1393 +            if (args_info->staticProps_group_counter && override)
1394 +              reset_group_staticProps (args_info);
1395 +            args_info->staticProps_group_counter += 1;
1396 +            break;
1397 +          }
1398            
1399            break;
1400          case '?':       /* Invalid option.  */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines