1 20 package org.apache.directory.ldapstudio.proxy.view.wrappers; 21 22 23 import java.util.Iterator ; 24 import java.util.List ; 25 26 import org.apache.directory.ldapstudio.proxy.model.LdapMessageWithPDU; 27 import org.apache.directory.ldapstudio.proxy.model.LdapProxy; 28 import org.apache.directory.ldapstudio.proxy.view.ProxyView; 29 30 31 37 public class LdapProxyWrapper extends AbstractWrapper 38 { 39 40 private ProxyView view; 41 42 43 49 public LdapProxyWrapper( ProxyView view ) 50 { 51 super( null ); 52 this.view = view; 53 } 54 55 56 59 protected void createChildren( List <IWrapper> children ) 60 { 61 LdapProxy ldapProxy = view.getLdapProxy(); 62 63 if ( ldapProxy != null ) 64 { 65 List <LdapMessageWithPDU> receivedLdapMessages = ldapProxy.getReceivedLdapMessages(); 66 for ( Iterator iter = receivedLdapMessages.iterator(); iter.hasNext(); ) 67 { 68 children.add( new LdapMessageWrapper( this, ( ( LdapMessageWithPDU ) iter.next() ) ) ); 69 } 70 } 71 System.out.println( "createChildren" ); 72 } 73 74 public void addChild( IWrapper element ) 75 { 76 fChildren.add( element ); 77 } 78 } 79 | Popular Tags |