⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 psqlscan.h

📁 PostgreSQL 8.1.4的源码 适用于Linux下的开源数据库系统
💻 H
字号:
/* * psql - the PostgreSQL interactive terminal * * Copyright (c) 2000-2005, PostgreSQL Global Development Group * * $PostgreSQL: pgsql/src/bin/psql/psqlscan.h,v 1.5 2005/01/01 05:43:08 momjian Exp $ */#ifndef PSQLSCAN_H#define PSQLSCAN_H#include "pqexpbuffer.h"#include "prompt.h"/* Abstract type for lexer's internal state */typedef struct PsqlScanStateData *PsqlScanState;/* Termination states for psql_scan() */typedef enum{	PSCAN_SEMICOLON,			/* found command-ending semicolon */	PSCAN_BACKSLASH,			/* found backslash command */	PSCAN_INCOMPLETE,			/* end of line, SQL statement incomplete */	PSCAN_EOL					/* end of line, SQL possibly complete */} PsqlScanResult;/* Different ways for scan_slash_option to handle parameter words */enum slash_option_type{	OT_NORMAL,					/* normal case */	OT_SQLID,					/* treat as SQL identifier */	OT_SQLIDHACK,				/* SQL identifier, but don't downcase */	OT_FILEPIPE,				/* it's a filename or pipe */	OT_WHOLE_LINE,				/* just snarf the rest of the line */	OT_VERBATIM					/* literal (no backticks or variables) */};extern PsqlScanState psql_scan_create(void);extern void psql_scan_destroy(PsqlScanState state);extern void psql_scan_setup(PsqlScanState state,				const char *line, int line_len);extern void psql_scan_finish(PsqlScanState state);extern PsqlScanResult psql_scan(PsqlScanState state,		  PQExpBuffer query_buf,		  promptStatus_t *prompt);extern void psql_scan_reset(PsqlScanState state);extern bool psql_scan_in_quote(PsqlScanState state);extern char *psql_scan_slash_command(PsqlScanState state);extern char *psql_scan_slash_option(PsqlScanState state,					   enum slash_option_type type,					   char *quote,					   bool semicolon);extern void psql_scan_slash_command_end(PsqlScanState state);extern void psql_scan_slash_pushback(PsqlScanState state, const char *str);#endif   /* PSQLSCAN_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -