# Does this break encapsulation?

**URL:** https://forum.kirupa.com/t/does-this-break-encapsulation/234301
**Category:** flash
**Created:** [August 1, 2007, 7:03am UTC](https://forum.kirupa.com/t/does-this-break-encapsulation/234301 "2007-08-01T07:03:15Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Flashthinker](https://avatars.discourse-cdn.com/v4/letter/f/dbc845/32.png) [@Flashthinker](https://forum.kirupa.com/u/Flashthinker)
#### Post date: [August 1, 2007, 7:03am UTC](https://forum.kirupa.com/t/does-this-break-encapsulation/234301/1 "2007-08-01T07:03:15Z")

</div>

Hi, I’ve been thinking about something which I do all the time and I’m wondering if it breaks the rule of encapsulation…  
Very often, I like to initialize certain objects in classes which are higher in the hierarchy (closer to the stage) because I find that it’s easier to make changes from there. Anyway, then, I like to pass these objects to ‘manager’ classes which control the properties of this object such as position, size, etc…

Since I am altering a class outside of the original class it was created in, does that break encapsulation? Or does encapsulation only apply to objects that are returned from child classes? In other words; is it OK to allow the child of a class to edit the properties of its ‘siblings’ (siblings to that child class… that is).

I just really like the fact that you can instantiate an object once and then pass it to multiple different manager classes.
