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

  • Home
  • SEARCH
  • 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 7914471
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T14:07:41+00:00 2026-06-03T14:07:41+00:00

My other programmer download this code from the net #import UIImage+Alpha.h // Private helper

  • 0

My other programmer download this code from the net

#import "UIImage+Alpha.h"

// Private helper methods
@interface UIImage ()
- (CGImageRef)newBorderMask:(NSUInteger)borderSize size:(CGSize)size;
@end

@implementation UIImage (Alpha)

I got error:
What causes Category is implementing a method which will also be implemented by its primary class?

I search for newBorderMask in my whole files and the word only show up 3 times.

It’s only declared once namely on

@interface UIImage ()
- (CGImageRef)newBorderMask:(NSUInteger)borderSize size:(CGSize)size;
@end

Implemented once namely in

#pragma mark -
#pragma mark Private helper methods

// Creates a mask that makes the outer edges transparent and everything else opaque
// The size must include the entire mask (opaque part + transparent border)
// The caller is responsible for releasing the returned reference by calling CGImageRelease
- (CGImageRef)newBorderMask:(NSUInteger)borderSize size:(CGSize)size1 {
    CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceGray();

and called once

 CGImageRef maskImageRef = [self newBorderMask:borderSize size:newRect.size];

So there is no double declaration.

So what’s the problem.

  • 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-06-03T14:07:43+00:00Added an answer on June 3, 2026 at 2:07 pm

    I am the original author of the code, and Aadhira’s answer is incorrect. The category name for this method should not be changed to “Alpha”, as the method is intended to be private and not part of the extension.

    To get rid of the warning, the best workaround is to give the private category a unique name, such as “PrivateAlpha”.

    For more details, see this discussion.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Say some programmer gives me an executable jar (from Java code) along with the
I am debugging some other programmer's source code of a Windows Media Player plugin.
I'm a relatively new C programmer, and I've noticed that many conventions from other
when the average ASP.net C# programmer (with very poor JavaScript knowledge other than scripting
I'm a first time Objective C programmer. I've been reading other people's code and
I'm developing a library which the other programmer will import and use it for
In reading other programmer's C++ code I am confused when the method takes 3
I am a programmer with strong background in Java, Ruby, Python and other high
I have some dll's for which i want to run code coverage using TestDriven.net
Aspiring programmer here! You can skip this part if you find it irrelevant. Im

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.