Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6092705
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T12:28:31+00:00 2026-05-23T12:28:31+00:00

In order to improve the client/server behaviour, I’m looking for adapt my iphone client

  • 0

In order to improve the client/server behaviour, I’m looking for adapt my iphone client code to proceed ziped responses.

The server adapt the SOAP response ziped.

I was looking how to uncompress the response but didn’t work for me.

The first solution I studied was the ZipArchive, explained here, solution (from minizip) but it is focus on filesystem compression.

And I just need to uncompress a NSString.

After that I checked this second approach:

NSData *decodedGzippedData = [NSData dataFromBase64String:encodedGzippedString];
NSData* unGzippedJsonData = [ASIHTTPRequest uncompressZippedData:decodedGzippedData];   
NSString* unGzippedJsonString = [[NSString alloc] initWithData:unGzippedJsonData encoding:NSASCIIStringEncoding];       

But didn’t work for me, because in the actual version the NSData dataFromBase64String didn’t exists.

Now I’m working with the third response of the previous question, anybody knows which library or framework I need to install in order to import Base64.h and NSData+Compression.h ¿? Used in this other potencial solution

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T12:28:32+00:00Added an answer on May 23, 2026 at 12:28 pm

    The solution was the next.

    Install the next libraries to your project:

    • Base64.h // You can find it here
    • NSData+Compression.h // You can find it here

    Use the code of one of the previous solutions

    #import "Base64.h"
    #import "NSData+compression.h"
    
    ...
    
    // decoding the base64 ziped message
    Byte inputData[[stringValue lengthOfBytesUsingEncoding:NSUTF8StringEncoding]];
    [[stringValue dataUsingEncoding:NSUTF8StringEncoding] getBytes:inputData];
    size_t inputDataSize = (size_t)[stringValue length];
    size_t outputDataSize = EstimateBas64DecodedDataSize(inputDataSize);
    Byte outputData[outputDataSize];//prepare a Byte[] for the decoded data
    Base64DecodeData(inputData, inputDataSize, outputData, &outputDataSize);
    
    // inflate the original string using gzip
    NSData *theData = [[NSData alloc] initWithBytes:outputData length:outputDataSize];
    NSData* result = [theData gzipInflate];//make bigger==gunzip
    
    // Return the result
    return [[NSString alloc] initWithData:result encoding:NSUTF8StringEncoding];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've been looking for ways to improve the overall attractiveness of my iPhone applications.
In order to improve type safety in some C library code, I got the
In order to improve code readability, sometimes I use alias methods. These are basically
In order to improve my open source project, I need testers. I have created
In order to improve performance reading from a file, I'm trying to read the
I'm trying to 'AJAX-ify' my site in order to improve the UI experience. In
In order to perform a case-sensitive search/replace on a table in a SQL Server
In order to improve the deployment / build process of my ASP.NET app, I
In order to improve the performance of a query I have created a denormalized
I am writing a multi-threaded application in Java in order to improve performance over

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.