Code Monkey home page Code Monkey logo

cron-expression-descriptor's People

Contributors

angloibs avatar eddyduong3010 avatar hmiguim avatar voidburn avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

cron-expression-descriptor's Issues

Hey

Manco l'email funziona più oramai ti posso contattare solo via github 😂 mandami una email a [email protected] che volevo sapere come stai. Magari un modo per chattare?

Not able to import library

Hello, I've been trying to use this library but I don't know how to import it. I already modified my build.gradle and added everything but how can I make the import in my code?

Exception when year above 2099.

Why is there no support when creating a description for a cron expression when the 'year' is above 2099.

Example:
CronExpressionDescriptor.getDescription("0 0 0 1 1 ? 2200");

Exception:

it.burning.cron.CronExpressionParser$CronExpressionParseException: The expression describing the YEAR field is not in a valid format. Accepted year values are 1970-2099
	at it.burning.cron.CronExpressionParser.parse(CronExpressionParser.java:497) ~[cron-expression-descriptor-1.2.6.jar:na]
	at it.burning.cron.CronExpressionDescriptor.getDescription(CronExpressionDescriptor.java:212) ~[cron-expression-descriptor-1.2.6.jar:na]
	at it.burning.cron.CronExpressionDescriptor.getDescription(CronExpressionDescriptor.java:871) ~[cron-expression-descriptor-1.2.6.jar:na]
	at it.burning.cron.CronExpressionDescriptor.getDescription(CronExpressionDescriptor.java:860) ~[cron-expression-descriptor-1.2.6.jar:na]

config Locale "zh" result error

   config   Locale  "zh"  

   CronExpressionDescriptor.setDefaultLocale("zh");
   CronExpressionDescriptor.getDescription("0-10 11 * * *");


   the result  is   � %s � %s ������   error 

Human readable day field is not the same as the parent C# library for JEE Timer ScheduleExpression

Hi I've just noticed that if you for example have the following cron string:

0 0 13 * * 1

the parent c# library returns At 01:00 PM, only on Monday
while this one in the default config returns: At 13:00, only on Sunday or with 24h display turned off: At 01:00 PM, only on Sunday

Afaik 0/7 would be sunday and then 1 should be monday as written for the JEE Timer classes: https://docs.oracle.com/javaee/7/tutorial/ejb-basicexamples004.htm

This leads to 0 being shifted to -1 here in CronExpressionParser for a valid JEE expression:

            if (partsCount == 5) {
                if (dowDigits.equals("7")) {
                    dowDigitsAdjusted = "0";
                }
            } else {
                // If the expression has more than 5 parts (which means it includes seconds and/or years), Sunday is specified as 1 and Saturday is specified as 7.
                // To normalize, we bring it back in the 0-6 range.
                //
                // See Quartz cron triggers (http://www.quartz-scheduler.org/documentation/quartz-2.3.0/tutorials/crontrigger.html)
                dowDigitsAdjusted = String.valueOf(Integer.parseInt(dowDigits) - 1);
            }

Would you be willing to support JEE crons as well?

Best regards,

Fabian

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.