tttar_spec.h 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. /*
  2. * CDE - Common Desktop Environment
  3. *
  4. * Copyright (c) 1993-2012, The Open Group. All rights reserved.
  5. *
  6. * These libraries and programs are free software; you can
  7. * redistribute them and/or modify them under the terms of the GNU
  8. * Lesser General Public License as published by the Free Software
  9. * Foundation; either version 2 of the License, or (at your option)
  10. * any later version.
  11. *
  12. * These libraries and programs are distributed in the hope that
  13. * they will be useful, but WITHOUT ANY WARRANTY; without even the
  14. * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
  15. * PURPOSE. See the GNU Lesser General Public License for more
  16. * details.
  17. *
  18. * You should have received a copy of the GNU Lesser General Public
  19. * License along with these libraries and programs; if not, write
  20. * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
  21. * Floor, Boston, MA 02110-1301 USA
  22. */
  23. /*%% (c) Copyright 1993, 1994 Hewlett-Packard Company */
  24. /*%% (c) Copyright 1993, 1994 International Business Machines Corp. */
  25. /*%% (c) Copyright 1993, 1994 Sun Microsystems, Inc. */
  26. /*%% (c) Copyright 1993, 1994 Novell, Inc. */
  27. /*%% $XConsortium: tttar_spec.h /main/3 1995/10/20 17:00:53 rswiston $ */
  28. /*
  29. * tttar_spec.h - Interface to specs for the Link Service/ToolTalk archive tool
  30. *
  31. * Copyright (c) 1990 by Sun Microsystems, Inc.
  32. *
  33. */
  34. #ifndef _LSTAR_SPEC_H
  35. #define _LSTAR_SPEC_H
  36. declare_list_of(Lstar_spec_prop)
  37. class Lstar_spec : public _Tt_object {
  38. public:
  39. Lstar_spec();
  40. Lstar_spec( _Tt_string id, _Tt_string path );
  41. ~Lstar_spec();
  42. _Tt_string id() {return _id;}
  43. _Tt_string path() {return _path;}
  44. void path_set( _Tt_string p ) {_path = p;}
  45. bool_t xdr( XDR *xdrs );
  46. Tt_status read_self();
  47. char *write_self( _Tt_string where,
  48. bool_t preserve__props,
  49. Tt_status *err );
  50. void print(FILE *fs = stdout) const;
  51. static void do_print(const _Tt_ostream &os,
  52. const _Tt_object *obj);
  53. private:
  54. _Tt_string _id;
  55. _Tt_string _type;
  56. _Tt_string _path;
  57. Lstar_spec_prop_list_ptr _props;
  58. };
  59. class Lstar_spec_prop : public _Tt_object {
  60. public:
  61. Lstar_spec_prop();
  62. Lstar_spec_prop( _Tt_string spec_id, _Tt_string propname );
  63. ~Lstar_spec_prop();
  64. bool_t xdr( XDR *xdrs );
  65. Tt_status write_self( char *spec_id,
  66. bool_t preserve__props);
  67. void print(FILE *fs = stdout) const;
  68. static void do_print(FILE *fs, const _Tt_object *obj);
  69. private:
  70. _Tt_string _propname;
  71. _Tt_string_list_ptr _values;
  72. };
  73. #endif /* _LSTAR_SPEC_H */