-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
2. add methods to UriBuilder in Provider class 3. improve plugin
- Loading branch information
1 parent
d4ff92d
commit 69f1b97
Showing
9 changed files
with
278 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
android-annotatedsql-processor/src/main/java/com/annotatedsql/processor/logger/ILogger.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
package com.annotatedsql.processor.logger; | ||
|
||
import java.util.Collection; | ||
|
||
import javax.lang.model.element.Element; | ||
|
||
/** | ||
* Created by hamsterksu on 20.10.2014. | ||
*/ | ||
public interface ILogger { | ||
void w(String msg); | ||
|
||
void w(String msg, Element element); | ||
|
||
void i(String msg); | ||
|
||
void i(String msg, Element element); | ||
|
||
void e(String msg, Throwable e, Element element); | ||
|
||
void e(String msg, Throwable e); | ||
|
||
void e(String msg, Element e); | ||
|
||
void e(String msg, Element... elms); | ||
|
||
void e(String msg, Collection<? extends Element> elms); | ||
} |
70 changes: 70 additions & 0 deletions
70
...oid-annotatedsql-processor/src/main/java/com/annotatedsql/processor/logger/TagLogger.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
package com.annotatedsql.processor.logger; | ||
|
||
import com.annotatedsql.processor.ProcessorLogger; | ||
|
||
import java.util.Collection; | ||
|
||
import javax.lang.model.element.Element; | ||
|
||
/** | ||
* Created by hamsterksu on 20.10.2014. | ||
*/ | ||
public class TagLogger implements ILogger{ | ||
|
||
private final ProcessorLogger logger; | ||
private final String tag; | ||
|
||
public TagLogger(String tag, ProcessorLogger logger) { | ||
this.tag = tag; | ||
this.logger = logger; | ||
} | ||
|
||
public ProcessorLogger getLogger() { | ||
return logger; | ||
} | ||
|
||
@Override | ||
public void w(String msg) { | ||
logger.w("[" + tag + "] " + msg); | ||
} | ||
|
||
@Override | ||
public void w(String msg, Element element) { | ||
logger.w("[" + tag + "] " + msg, element); | ||
} | ||
|
||
@Override | ||
public void i(String msg) { | ||
logger.i("[" + tag + "] " + msg); | ||
} | ||
|
||
@Override | ||
public void i(String msg, Element element) { | ||
logger.i("[" + tag + "] " + msg, element); | ||
} | ||
|
||
@Override | ||
public void e(String msg, Throwable e, Element element) { | ||
logger.e("[" + tag + "] " + msg, e, element); | ||
} | ||
|
||
@Override | ||
public void e(String msg, Throwable e) { | ||
logger.e("[" + tag + "] " + msg, e); | ||
} | ||
|
||
@Override | ||
public void e(String msg, Element e) { | ||
logger.e("[" + tag + "] " + msg, e); | ||
} | ||
|
||
@Override | ||
public void e(String msg, Element... elms) { | ||
logger.e("[" + tag + "] " + msg, elms); | ||
} | ||
|
||
@Override | ||
public void e(String msg, Collection<? extends Element> elms) { | ||
logger.e("[" + tag + "] " + msg, elms); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.