tilde.h
上传用户:tsgydb
上传日期:2007-04-14
资源大小:10674k
文件大小:3k
源码类别:

MySQL数据库

开发平台:

Visual C++

  1. /* tilde.h: Externally available variables and function in libtilde.a. */
  2. /* Copyright (C) 1992 Free Software Foundation, Inc.
  3.    This file contains the Readline Library (the Library), a set of
  4.    routines for providing Emacs style line input to programs that ask
  5.    for it.
  6.    The Library is free software; you can redistribute it and/or modify
  7.    it under the terms of the GNU General Public License as published by
  8.    the Free Software Foundation; either version 1, or (at your option)
  9.    any later version.
  10.    The Library is distributed in the hope that it will be useful, but
  11.    WITHOUT ANY WARRANTY; without even the implied warranty of
  12.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  13.    General Public License for more details.
  14.    The GNU General Public License is often shipped with GNU software, and
  15.    is generally kept in a file called COPYING or LICENSE.  If you do not
  16.    have a copy of the license, write to the Free Software Foundation,
  17.    675 Mass Ave, Cambridge, MA 02139, USA. */
  18. #if !defined (_TILDE_H_)
  19. #  define _TILDE_H_
  20. /* Function pointers can be declared as (Function *)foo. */
  21. #if !defined (_FUNCTION_DEF)
  22. #  define _FUNCTION_DEF
  23. typedef int Function ();
  24. typedef void VFunction ();
  25. typedef char *CPFunction ();
  26. typedef char **CPPFunction ();
  27. #endif /* _FUNCTION_DEF */
  28. /* If non-null, this contains the address of a function that the application
  29.    wants called before trying the standard tilde expansions.  The function
  30.    is called with the text sans tilde, and returns a malloc()'ed string
  31.    which is the expansion, or a NULL pointer if the expansion fails. */
  32. extern CPFunction *tilde_expansion_preexpansion_hook;
  33. /* If non-null, this contains the address of a function to call if the
  34.    standard meaning for expanding a tilde fails.  The function is called
  35.    with the text (sans tilde, as in "foo"), and returns a malloc()'ed string
  36.    which is the expansion, or a NULL pointer if there is no expansion. */
  37. extern CPFunction *tilde_expansion_failure_hook;
  38. /* When non-null, this is a NULL terminated array of strings which
  39.    are duplicates for a tilde prefix.  Bash uses this to expand
  40.    `=~' and `:~'. */
  41. extern char **tilde_additional_prefixes;
  42. /* When non-null, this is a NULL terminated array of strings which match
  43.    the end of a username, instead of just "/".  Bash sets this to
  44.    `:' and `=~'. */
  45. extern char **tilde_additional_suffixes;
  46. /* Return a new string which is the result of tilde expanding STRING. */
  47. extern char *tilde_expand ();
  48. /* Do the work of tilde expansion on FILENAME.  FILENAME starts with a
  49.    tilde.  If there is no expansion, call tilde_expansion_failure_hook. */
  50. extern char *tilde_expand_word ();
  51. #endif /* _TILDE_H_ */