protected void mergeMailingList_Subscribe( MailingList target, MailingList source, boolean sourceDominant, Map<Object, Object> context ) { String src = source.getSubscribe(); if ( src != null ) { if ( sourceDominant || target.getSubscribe() == null ) { target.setSubscribe( src ); target.setLocation( "subscribe", source.getLocation( "subscribe" ) ); } } }
public static MailingList cloneMailingList( MailingList src ) { if ( src == null ) { return null; } MailingList result = new MailingList(); result.setArchive( src.getArchive() ); result.setName( src.getName() ); result.setOtherArchives( src.getOtherArchives() ); result.setPost( src.getPost() ); result.setSubscribe( src.getSubscribe() ); result.setUnsubscribe( src.getUnsubscribe() ); return result; }
if ( mailingList.getSubscribe() != null ) serializer.startTag( NAMESPACE, "subscribe" ).text( mailingList.getSubscribe() ).endTag( NAMESPACE, "subscribe" );
private void mailingLists( List<MailingList> mailingLists ) { for( MailingList list : mailingLists ) { p.printStartBlock( "mailing_list", list.getName() ); p.println( "subscribe", list.getSubscribe() ); p.println( "unsubscribe", list.getUnsubscribe() ); p.println( "post", list.getPost() ); // not thread safe !! list.getOtherArchives().add( 0, list.getArchive() ); p.println( "archives", toArray( list.getOtherArchives() ) ); // keep model as is - not thread safe !! list.getOtherArchives().remove( 0 ); p.printEndBlock(); p.println(); } }
if ( mailingList.getSubscribe() != null ) serializer.attribute( NAMESPACE, "subscribe", mailingList.getSubscribe() );
protected void mergeMailingList_Subscribe( MailingList target, MailingList source, boolean sourceDominant, Map<Object, Object> context ) { String src = source.getSubscribe(); if ( src != null ) { if ( sourceDominant || target.getSubscribe() == null ) { target.setSubscribe( src ); target.setLocation( "subscribe", source.getLocation( "subscribe" ) ); } } }
private List<org.apache.archiva.metadata.model.MailingList> convertMailingLists( List<MailingList> mailingLists ) { List<org.apache.archiva.metadata.model.MailingList> l = new ArrayList<>(); for ( MailingList mailingList : mailingLists ) { org.apache.archiva.metadata.model.MailingList newMailingList = new org.apache.archiva.metadata.model.MailingList(); newMailingList.setName( mailingList.getName() ); newMailingList.setMainArchiveUrl( mailingList.getArchive() ); newMailingList.setPostAddress( mailingList.getPost() ); newMailingList.setSubscribeAddress( mailingList.getSubscribe() ); newMailingList.setUnsubscribeAddress( mailingList.getUnsubscribe() ); newMailingList.setOtherArchives( mailingList.getOtherArchives() ); l.add( newMailingList ); } return l; }
private List<org.apache.archiva.metadata.model.MailingList> convertMailingLists( List<MailingList> mailingLists ) { List<org.apache.archiva.metadata.model.MailingList> l = new ArrayList<>(); for ( MailingList mailingList : mailingLists ) { org.apache.archiva.metadata.model.MailingList newMailingList = new org.apache.archiva.metadata.model.MailingList(); newMailingList.setName( mailingList.getName() ); newMailingList.setMainArchiveUrl( mailingList.getArchive() ); newMailingList.setPostAddress( mailingList.getPost() ); newMailingList.setSubscribeAddress( mailingList.getSubscribe() ); newMailingList.setUnsubscribeAddress( mailingList.getUnsubscribe() ); newMailingList.setOtherArchives( mailingList.getOtherArchives() ); l.add( newMailingList ); } return l; }
private void mailingLists( List<MailingList> mailingLists ) { for( MailingList list : mailingLists ) { p.printStartBlock( "mailing_list", list.getName() ); p.println( "subscribe", list.getSubscribe() ); p.println( "unsubscribe", list.getUnsubscribe() ); p.println( "post", list.getPost() ); // not thread safe !! list.getOtherArchives().add( 0, list.getArchive() ); p.println( "archives", toArray( list.getOtherArchives() ) ); // keep model as is - not thread safe !! list.getOtherArchives().remove( 0 ); p.printEndBlock(); p.println(); } }
private void mailingLists( List<MailingList> mailingLists ) { for( MailingList list : mailingLists ) { p.printStartBlock( "mailing_list", list.getName() ); p.println( "subscribe", list.getSubscribe() ); p.println( "unsubscribe", list.getUnsubscribe() ); p.println( "post", list.getPost() ); // not thread safe !! list.getOtherArchives().add( 0, list.getArchive() ); p.println( "archives", toArray( list.getOtherArchives() ) ); // keep model as is - not thread safe !! list.getOtherArchives().remove( 0 ); p.printEndBlock(); p.println(); } }
if ( mailingList.getSubscribe() != null ) element.addElement( "subscribe" ).setText( mailingList.getSubscribe() );
if ( mailingList.getSubscribe() != null ) serializer.startTag( NAMESPACE, "subscribe" ).text( mailingList.getSubscribe() ).endTag( NAMESPACE, "subscribe" );
if ( mailingList.getSubscribe() != null ) serializer.startTag( NAMESPACE, "subscribe" ).text( mailingList.getSubscribe() ).endTag( NAMESPACE, "subscribe" );
/** * Method updateMailingList * * @param value * @param element * @param counter * @param xmlTag */ protected void updateMailingList( MailingList value, String xmlTag, Counter counter, Element element ) { Element root = element; Counter innerCount = new Counter( counter.getDepth() + 1 ); findAndReplaceSimpleElement( innerCount, root, "name", value.getName(), null ); findAndReplaceSimpleElement( innerCount, root, "subscribe", value.getSubscribe(), null ); findAndReplaceSimpleElement( innerCount, root, "unsubscribe", value.getUnsubscribe(), null ); findAndReplaceSimpleElement( innerCount, root, "post", value.getPost(), null ); findAndReplaceSimpleElement( innerCount, root, "archive", value.getArchive(), null ); findAndReplaceSimpleLists( innerCount, root, value.getOtherArchives(), "otherArchives", "otherArchive" ); } // -- void updateMailingList(MailingList, String, Counter, Element)
/** * Method updateMailingList * * @param value * @param element * @param counter * @param xmlTag */ protected void updateMailingList( MailingList value, String xmlTag, Counter counter, Element element ) { Element root = element; Counter innerCount = new Counter( counter.getDepth() + 1 ); findAndReplaceSimpleElement( innerCount, root, "name", value.getName(), null ); findAndReplaceSimpleElement( innerCount, root, "subscribe", value.getSubscribe(), null ); findAndReplaceSimpleElement( innerCount, root, "unsubscribe", value.getUnsubscribe(), null ); findAndReplaceSimpleElement( innerCount, root, "post", value.getPost(), null ); findAndReplaceSimpleElement( innerCount, root, "archive", value.getArchive(), null ); findAndReplaceSimpleLists( innerCount, root, value.getOtherArchives(), "otherArchives", "otherArchive" ); } // -- void updateMailingList(MailingList, String, Counter, Element)
/** * Method updateMailingList. * * @param value * @param element * @param counter * @param xmlTag */ protected void updateMailingList(MailingList value, String xmlTag, Counter counter, Element element) { Element root = element; Counter innerCount = new Counter(counter.getDepth() + 1); findAndReplaceSimpleElement(innerCount, root, "name", value.getName(), null); findAndReplaceSimpleElement(innerCount, root, "subscribe", value.getSubscribe(), null); findAndReplaceSimpleElement(innerCount, root, "unsubscribe", value.getUnsubscribe(), null); findAndReplaceSimpleElement(innerCount, root, "post", value.getPost(), null); findAndReplaceSimpleElement(innerCount, root, "archive", value.getArchive(), null); findAndReplaceSimpleLists(innerCount, root, value.getOtherArchives(), "otherArchives", "otherArchive"); } // -- void updateMailingList(MailingList, String, Counter, Element)
/** * Method updateMailingList * * @param value * @param element * @param counter * @param xmlTag */ protected void updateMailingList(MailingList value, String xmlTag, Counter counter, Element element) { Element root = element; Counter innerCount = new Counter(counter.getDepth() + 1); findAndReplaceSimpleElement(innerCount, root, "name", value.getName(), null); findAndReplaceSimpleElement(innerCount, root, "subscribe", value.getSubscribe(), null); findAndReplaceSimpleElement(innerCount, root, "unsubscribe", value.getUnsubscribe(), null); findAndReplaceSimpleElement(innerCount, root, "post", value.getPost(), null); findAndReplaceSimpleElement(innerCount, root, "archive", value.getArchive(), null); findAndReplaceSimpleLists(innerCount, root, value.getOtherArchives(), "otherArchives", "otherArchive"); } //-- void updateMailingList(MailingList, String, Counter, Element)
/** * Method updateMailingList. * * @param value * @param element * @param counter * @param xmlTag */ protected void updateMailingList( MailingList value, String xmlTag, Counter counter, Element element ) { Element root = element; Counter innerCount = new Counter( counter.getDepth() + 1 ); findAndReplaceSimpleElement( innerCount, root, "name", value.getName(), null ); findAndReplaceSimpleElement( innerCount, root, "subscribe", value.getSubscribe(), null ); findAndReplaceSimpleElement( innerCount, root, "unsubscribe", value.getUnsubscribe(), null ); findAndReplaceSimpleElement( innerCount, root, "post", value.getPost(), null ); findAndReplaceSimpleElement( innerCount, root, "archive", value.getArchive(), null ); findAndReplaceSimpleLists( innerCount, root, value.getOtherArchives(), "otherArchives", "otherArchive" ); } // -- void updateMailingList(MailingList, String, Counter, Element)
/** * Method updateMailingList. * * @param value * @param element * @param counter * @param xmlTag */ protected void updateMailingList(MailingList value, String xmlTag, Counter counter, Element element) { Element root = element; Counter innerCount = new Counter(counter.getDepth() + 1); findAndReplaceSimpleElement(innerCount, root, "name", value.getName(), null); findAndReplaceSimpleElement(innerCount, root, "subscribe", value.getSubscribe(), null); findAndReplaceSimpleElement(innerCount, root, "unsubscribe", value.getUnsubscribe(), null); findAndReplaceSimpleElement(innerCount, root, "post", value.getPost(), null); findAndReplaceSimpleElement(innerCount, root, "archive", value.getArchive(), null); findAndReplaceSimpleLists(innerCount, root, value.getOtherArchives(), "otherArchives", "otherArchive"); } //-- void updateMailingList(MailingList, String, Counter, Element)
Counter innerCount = new Counter( counter.getDepth() + 1 ); findAndReplaceSimpleElement( innerCount, root, "name", value.getName(), null ); findAndReplaceSimpleElement( innerCount, root, "subscribe", value.getSubscribe(), null ); findAndReplaceSimpleElement( innerCount,