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

📄 t_setoption.c

📁 CCSM Research Tools: Community Atmosphere Model (CAM)
💻 C
字号:
/*** $Id: t_setoption.c,v 1.1 2001/04/19 00:03:07 rosinski Exp $*/#include <stdio.h>#include "gpt.h"/*** t_setoption: set option value to true or false.**** Input arguments:**   option: option to be set**   val:    value to which option should be set**** Return value: 0 (success) or -1 (failure)*/int t_setoption (OptionName option, Boolean val){  int n;#if ( defined DISABLE_TIMERS )  return 0;#endif  if (t_initialized)    return (t_error ("t_setoption: Options must be set BEFORE t_initialize\n"));  for (n = 0; n < npossible; n++) {    if (possible_event[n].name == option) {      possible_event[n].enabled = val;      if (val)	printf ("t_setoption: option enabled:  %s\n", possible_event[n].string);      else	printf ("t_setoption: option disabled: %s\n", possible_event[n].string);      return 0;    }  }  return (t_error ("t_setoption: Option with enum index %d not available\n",		     option));}

⌨️ 快捷键说明

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