hotspot/src/share/vm/services/diagnosticFramework.cpp
changeset 24424 2658d7834c6e
parent 17296 68557efd8583
child 27879 419385282044
equal deleted inserted replaced
24358:8528b67f6562 24424:2658d7834c6e
     1 /*
     1 /*
     2  * Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
   257     } else {
   257     } else {
   258       out->print(" [<%s>]", arg->name());
   258       out->print(" [<%s>]", arg->name());
   259     }
   259     }
   260     arg = arg->next();
   260     arg = arg->next();
   261   }
   261   }
   262   out->print_cr("");
   262   out->cr();
   263   if (_arguments_list != NULL) {
   263   if (_arguments_list != NULL) {
   264     out->print_cr("\nArguments:");
   264     out->print_cr("\nArguments:");
   265     arg = _arguments_list;
   265     arg = _arguments_list;
   266     while (arg != NULL) {
   266     while (arg != NULL) {
   267       out->print("\t%s : %s %s (%s, ", arg->name(),
   267       out->print("\t%s : %s %s (%s, ", arg->name(),
   268                  arg->is_mandatory() ? "" : "[optional]",
   268                  arg->is_mandatory() ? "" : "[optional]",
   269                  arg->description(), arg->type());
   269                  arg->description(), arg->type());
   270       if (arg->has_default()) {
   270       if (arg->has_default()) {
   271         out->print(arg->default_string());
   271         out->print("%s", arg->default_string());
   272       } else {
   272       } else {
   273         out->print("no default value");
   273         out->print("no default value");
   274       }
   274       }
   275       out->print_cr(")");
   275       out->print_cr(")");
   276       arg = arg->next();
   276       arg = arg->next();
   282     while (arg != NULL) {
   282     while (arg != NULL) {
   283       out->print("\t%s : %s %s (%s, ", arg->name(),
   283       out->print("\t%s : %s %s (%s, ", arg->name(),
   284                  arg->is_mandatory() ? "" : "[optional]",
   284                  arg->is_mandatory() ? "" : "[optional]",
   285                  arg->description(), arg->type());
   285                  arg->description(), arg->type());
   286       if (arg->has_default()) {
   286       if (arg->has_default()) {
   287         out->print(arg->default_string());
   287         out->print("%s", arg->default_string());
   288       } else {
   288       } else {
   289         out->print("no default value");
   289         out->print("no default value");
   290       }
   290       }
   291       out->print_cr(")");
   291       out->print_cr(")");
   292       arg = arg->next();
   292       arg = arg->next();