pike.git / lib / modules / Calendar.pmod / Event.pmod

version» Context lines:

pike.git/lib/modules/Calendar.pmod/Event.pmod:134:       //! This constant may be used to identify @[Day_Event] objects.    constant is_day_event=1;       //! Returned from @[scan_jd] if the even searched for did not    //! exist.    constant NODAY=-1;       int nd=1;    -  //! @decl int scan_jd(.Calendar realm,int jd,@ -  //! int(-1..-1)||int(1..1) direction) +  //! @decl int scan_jd(.Calendar realm, int jd,@ +  //! int(-1..-1)|int(1..1) direction)    //! These methods has to be defined, and is what    //! really does some work. It should return the next or previos    //! julian day (>@i{jd@}) when the event occurs,    //! or the constant @[NODAY] if it doesn't.    //!    //! @param direction    //! @int    //! @value 1    //! Forward (next),    //! @value -1
pike.git/lib/modules/Calendar.pmod/Event.pmod:555:   class Gregorian_Fixed   {    inherit Day_Event;       //! This constant may be used to identify @[Gregorian_Fixed] objects.    constant is_fixed=1;       int md,mn;    int yd;    -  //! @decl create(string id, string name, int(1..31) month_day,@ -  //! int(1..12) month, int extra) +  //! @decl void create(string id, string name, int(1..31) month_day,@ +  //! int(1..12) month, int extra)    void create(string _id,string _name,    int(1..31) _md,int(1..12) _mn,int ... _n)    {    id=_id;    name=_name;    md=_md;    mn=_mn;       yd=M_YD[mn]+md;    if (sizeof(_n)) nd=_n[0];
pike.git/lib/modules/Calendar.pmod/Event.pmod:750:    if (direction==1)    [y,yjd,leap]=gregorian_yjd(yjd+365+leap);    else    [y,yjd,leap]=gregorian_yjd(yjd-1);    }    }   }      //! This class represents the event that a given gregorian   //! day of month appears a given weekday. For instance, - //! @tt@{Event.Monthday_Weekday(13,5)->next(Day())@} finds the next + //! @tt{Event.Monthday_Weekday(13,5)->next(Day())@} finds the next   //! friday the 13th.   class Monthday_Weekday   {    inherit Day_Event;       int md;    int jd_wd;       //! @decl void create(int month_day,int weekday)    //! The event is created by a given month day,
pike.git/lib/modules/Calendar.pmod/Event.pmod:941:    }    else    {    if (ejd<=jd) return ejd;    [y,yjd,leap]=my_year(y-1);    }    }    }   }    - // This class represents an easter relative event. + //! This class represents an easter relative event.   class Easter_Relative   {    inherit Easter;       constant is_easter_relative=1;       int offset;       //! @decl void create(string id, string name, int offset)    void create(string _id,string _name,void|int _offset)
pike.git/lib/modules/Calendar.pmod/Event.pmod:971:    }       string describe()    {    return sprintf("%seaster %+2d, %s",    shift>2000?"orthodox ":"",    offset,WD_NAME[(offset-1)%7+1]);    }   }    - // This class represents an orthodox easter relative event. + //! This class represents an orthodox easter relative event.   class Orthodox_Easter_Relative   {    inherit Easter_Relative;       constant is_orthodox_easter_relative=1;       int offset;       //! @decl void create(string id, string name, int offset)    void create(string _id,string _name,void|int _offset)