|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.android.ide.common.res2.MergeWriter<ResourceItem>
com.android.ide.common.res2.MergedResourceWriter
public class MergedResourceWriter
A MergeWriter
for assets, using ResourceItem
.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface com.android.ide.common.res2.MergeConsumer |
---|
MergeConsumer.ConsumerException |
Field Summary | |
---|---|
static java.lang.String |
FILENAME_PREFIX
Prefix in comments which mark the source locations for merge results |
static java.lang.String |
FN_VALUES_XML
Filename to save the merged file as |
Constructor Summary | |
---|---|
MergedResourceWriter(java.io.File rootFolder,
com.android.ide.common.internal.PngCruncher pngRunner)
|
Method Summary | |
---|---|
void |
addItem(ResourceItem item)
Adds an item. |
void |
end()
Called after the merge ends. |
boolean |
ignoreItemInMerge(ResourceItem item)
|
boolean |
isInsertSourceMarkers()
Returns whether this manifest merger will insert source markers into the merged source |
protected void |
postWriteAction()
Called after all the items have been added/removed. |
void |
removeItem(ResourceItem removedItem,
ResourceItem replacedBy)
Removes an item. |
void |
setInsertSourceMarkers(boolean insertSourceMarkers)
Sets whether this manifest merger will insert source markers into the merged source |
void |
start()
Called before the merge starts. |
Methods inherited from class com.android.ide.common.res2.MergeWriter |
---|
getExecutor, getRootFolder |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String FN_VALUES_XML
public static final java.lang.String FILENAME_PREFIX
Constructor Detail |
---|
public MergedResourceWriter(@NonNull java.io.File rootFolder, @Nullable com.android.ide.common.internal.PngCruncher pngRunner)
Method Detail |
---|
public void setInsertSourceMarkers(boolean insertSourceMarkers)
insertSourceMarkers
- if true, insert source markerspublic boolean isInsertSourceMarkers()
public void start() throws MergeConsumer.ConsumerException
MergeConsumer
start
in interface MergeConsumer<ResourceItem>
start
in class MergeWriter<ResourceItem>
MergeConsumer.ConsumerException
public void end() throws MergeConsumer.ConsumerException
MergeConsumer
end
in interface MergeConsumer<ResourceItem>
end
in class MergeWriter<ResourceItem>
MergeConsumer.ConsumerException
public boolean ignoreItemInMerge(ResourceItem item)
public void addItem(@NonNull ResourceItem item) throws MergeConsumer.ConsumerException
MergeConsumer
DataItem.isTouched()
will
indicate whether the item actually changed.
item
- the new item.
MergeConsumer.ConsumerException
public void removeItem(@NonNull ResourceItem removedItem, @Nullable ResourceItem replacedBy) throws MergeConsumer.ConsumerException
MergeConsumer
removedItem
- the removed item.replacedBy
- the optional item that replaces the removed item.
MergeConsumer.ConsumerException
protected void postWriteAction() throws MergeConsumer.ConsumerException
MergeWriter
MergeWriter.end()
.
postWriteAction
in class MergeWriter<ResourceItem>
MergeConsumer.ConsumerException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |