Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump io.takari:takari from 51 to 55 #303

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@

import javax.inject.Named;
import javax.inject.Singleton;

import org.sonatype.maven.polyglot.mapping.MappingSupport;

/**
Expand All @@ -18,13 +17,13 @@
* @author dhanji@gmail.com (Dhanji R. Prasanna)
*/
@Singleton
@Named( "atom" )
@Named("atom")
public class AtomMapping extends MappingSupport {
public AtomMapping() {
super("atom");
setPomNames("pom.atom");
setAcceptLocationExtensions(".atom");
setAcceptOptionKeys("atom:4.0.0");
setPriority(1);
}
}
public AtomMapping() {
super("atom");
setPomNames("pom.atom");
setAcceptLocationExtensions(".atom");
setAcceptOptionKeys("atom:4.0.0");
setPriority(1);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,11 @@
*/
package org.sonatype.maven.polyglot.atom;

import javax.inject.Named;
import javax.inject.Singleton;

import java.io.IOException;
import java.io.Reader;
import java.util.Map;

import javax.inject.Named;
import javax.inject.Singleton;
import org.apache.maven.model.Model;
import org.apache.maven.model.building.ModelProcessor;
import org.apache.maven.model.building.ModelSource;
Expand All @@ -25,18 +23,21 @@

/**
* Reads a <tt>pom.atom</tt> and transforms into a Maven {@link Model}.
*
*
* @author dhanji@gmail.com (Dhanji R. Prasanna)
*/
@Singleton
@Named( "atom" )
@Named("atom")
public class AtomModelReader extends ModelReaderSupport {

public Model read(final Reader input, final Map<String, ?> options) throws IOException {
assert input != null;
public Model read(final Reader input, final Map<String, ?> options) throws IOException {
assert input != null;

// Parse the token stream from our pom.atom configuration file.
Project project = new AtomParser((ModelSource)options.get(ModelProcessor.SOURCE), new Tokenizer(IOUtil.toString(input)).tokenize()).parse();
return project.toMavenModel();
}
// Parse the token stream from our pom.atom configuration file.
Project project = new AtomParser(
(ModelSource) options.get(ModelProcessor.SOURCE),
new Tokenizer(IOUtil.toString(input)).tokenize())
.parse();
return project.toMavenModel();
}
}
Loading