• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: @Override of EO?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: @Override of EO?


  • Subject: Re: @Override of EO?
  • From: Christoph Wick <email@hidden>
  • Date: Fri, 02 Aug 2013 20:00:05 +0200

Primary keys are not set normally (sort of ...). And you should not override setter methods of EOs!

The method of your choice may be overriding EOEnterpriseObject.awakeFromInsertion(EOEditingContext ec).

If your class is e.g. Poster (and you use EOGenerator), then use

	public class Poster extends _Poster {

		@Override
		public void awakeFromInsertion(EOEditingContext ec) {
			super.awakeFromInsertion(ec);
			fireMyUnixProcess();
		}

	}

C.U.CW
--

Christoph Wick - Diplom Informatiker, Managing Director
i4innovation GmbH, Professor-Neu-Allee 39, 53225 Bonn, Germany

T +49 2 28 28 62 97 93
M +49 1 51 22 65 78 90
F +49 2 28 28 62 97 99
M email@hidden
W www.i4innovation.de

Geschäftsführer: Thomas Heep, Christoph Wick
Sitz der Gesellschaft: Bonn | Amtsgericht Bonn HRB 18548 | USt-IdNr.: DE276502600


On 02.08.2013, at 19:21, Jesse Tayler <email@hidden> wrote:

>
> I have an override of a normal EO setter, but for some reason, it isn’t called but the value does get updated
>
> I really just want to fire off a unix process once a new posterId has been set, so maybe there’s a smarter way but I thought this would be reliably called once and only after there’s a known primary key id for that poster (ERAttachment)
>
> Any thoughts on that?
>
>
>    @Override
>    public void setPosterId(Integer value) {
>
>
>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list      (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: @Override of EO?
      • From: Jesse Tayler <email@hidden>
References: 
 >@Override of EO? (From: Jesse Tayler <email@hidden>)

  • Prev by Date: @Override of EO?
  • Next by Date: Re: @Override of EO?
  • Previous by thread: @Override of EO?
  • Next by thread: Re: @Override of EO?
  • Index(es):
    • Date
    • Thread