Giter Site home page Giter Site logo

mohsinalimat / azcalendar Goto Github PK

View Code? Open in Web Editor NEW

This project forked from aliazadeh/azcalendar

1.0 2.0 0.0 247 KB

AZCalendar is library for IOS that support georgian calendar , Persian calendar , hijri calendar (islamic calendar) , you can convert dates from each calendar to each others simply

Objective-C 38.45% Swift 48.93% C 12.62%

azcalendar's Introduction

AZCalendar

AZCalendar is a framework for IOS it has gregorian calendar , persian calendar hijri calendar (islamic calendar) , and you can convert dates from each calendar to each other simply

alt tag

Installation :

Simply use the Frame work that it is in the framework directory for ObjectiveC projects or Swift and ## don’t forget to add the general->Embedded Binaries

Usage :

for Using AZCalendar you Don't need instance Object of this Class you can call function with class name 'AZCalendar

Geting today's date :

for getting today info you can use AZCalendar.getCurrentPersianDate() , AZCalendar.getCurrentHijriDate() and AZCalendar.getCurrentGregorianDate() that returns a DateType instance that has day and month and year as Int

if you want to know the month name in each calendar type use AZCalendar.getMonthName that wants a DateType Object and your Clander type , CalendarType is enum that has 3 value persian , gregorian and hijri

if you want know the day of week you can use AZCalendar.getDayIndex that return the Int 0 means to day is Sunday , 1 means today is Monday and …

Converting dates :

for converting date to each others you can use the AZCalendar.convertDate that it wants a instance of DateType and the origin and destination calendarType and returns a DateType Obkect ###Example :

let source = DateType.init(day: 5, month: 8, year: 1395) let gregorian = AZCalendar.convertDate(inputType: .persian, inputDate: source, outputType: .gregorian)

now the gregorian object hasr 3 field that day is = 26 , month = 10 and year is 2016

azcalendar's People

Contributors

aliazadeh avatar

Stargazers

MohsinAli avatar

Watchers

MohsinAli avatar  avatar

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.