Coder Social home page Coder Social logo

jagpropertyconverter's People

Contributors

jagill avatar lucdion avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

jagpropertyconverter's Issues

convertToDate - handling 2 different date types

If the json object has two date string objects (say, 2013-03-02, 2013-03-02 10:15), can't the convertToDate message handle these formats.

JAGPropertyConverter *converter = [[JAGPropertyConverter alloc] initWithOutputType:kJAGJSONOutput] ;

[converter setConvertToDate:^(id d1)
{
return [NSDate convertFromStringDate:d1 usingFormatterString:DT_yyyy_MM_dd_HH_mm_ss];
} ];

    [converter setConvertToDate:^(id d2)
     {
         return [NSDate convertFromStringDate:d12 usingFormatterString:DT_yyyy_MM_dd];

     }];

I have written a custom method on NSDate to convert different string date formats. What I am seeing is that, I can use only one at any point of time.
Commenting either of the above works fine for the individual date string objects. However if uncomment both of the above, only one gets converted. This lead me to believe that I can convert only one date string object ? Am I missing something. Thanks in advance for your reply.

JAG Property Converter......

Hi

I am trying to use this "JAG Property Converter" Library but it is giving me too much errors.
I just want to know that where are the steps for this library to be implemented in existing project in IOS.
Did you have given the steps?
I didn't find them in whole readme note.
Please provide the steps so that i can use this for my project.
Reply me please.

Thanks and Regards,
Jittender K Thakur

Model composed of different Model

Hi,
Is this recursive supposed to address a model composed of different models. In this case dataBlock(see below) is composed of applicationBlock and passwordBlock in addition to the key value pairs. Is this use case applicable for the JAGPropertyConverter project.

dataBlock: {
applicationBlock:
{
majorVersion: "2",
minorVersion: "0",
subVersion: "0",
rcVersion: "16",
environment: "TEVV"
}
,
prefix: "",
suffix: "",
image: "",
pneumonic: "FNLN",
firstName: "First Name",
middleName: "",
lastName: "Last Name",
email: "[email protected]",
tempKey: "ctfdkl7c852d5568960adc854f92d7",
failedLogin: "0",
passwordDate: "2012-08-28",
tempPasswordFlag: "N",
lockedFlag: "N",
activeFlag: "Y",
ersAdminFlag: "0",
speciality: "1",
role: "63",
passwordBlock:
{
pwdMaxBadLogin: "5",
pwdTimeout: "90",
pwdHistoryCount: "10",
pwdNumberCount: "1",
pwdUpperCaseCount: "1",
pwdLowerCaseCount: "1",
pwdSpecialCount: "1",
pwdMinLength: "6",
pwdMaxLength: "16",
pwdNotificationText: "Validation text string.",
systemUserFilter: "5,6"
}

}

how to handle nested json?

hi,
{
"userID" : 1234,
"name" : "Jane Smith",
"likes" : ["swimming", "movies", "tennis"],
"invitedBy" : {
"userID" : 9876,
"name" : "Bob Willis"
}
}

now, key "likes" is a NSArray, if it contains model array but not string value, how to handle it?
how about add another block method like "converter.identifyArray"?
thanks.

Nested Objects

Does this class parse nested objects, for example, if you had a parent object, with child objects, with grand child objects. I couldn't see any examples, maybe I've missed it. Thanks in advance.

Converting JSON into NSArray

If my dictionary is a list of objects, how would I convert a dictionary of this type into an NSArray of my objects?

For example [{"Id":1,"Name":"ABC"},{"Id":2,"Name":"DEF"}]

Going into:

@interface Survey : NSObject

@property (assign) int Id;
@property (nonatomic, copy) NSString *Name;

@EnD

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.